:root {
    --yellow: #FFD23C;
    --orange: #C55203;
    --red_lite: #E7826D;
    --red: #FF4646;
    --red_dark: #810505;
    --green: #058143;
    --green_lite: #8DC63F;
    --blue: #0D76C4;
    --blue_dark: #03386B;
    --black: #000;
}

.yellow {
    color: var(--yellow);
}

.orange {
    color: var(--orange);
}

.green {
    color: var(--green);
}

.blue {
    color: var(--blue);
}

.blue_dark {
    color: var(--blue_dark);
}

.box_shadow {
    box-shadow: 17px -12px 0 rgba(0, 0, 0, .3);
}

.skranji {
    font-family: skranji, sans-serif;
}

.skranji-bold {
    font-family: skranji, sans-serif;
    font-weight: 700;
}

.barlow {
    font-family: barlow, sans-serif;
}

#firstwrapper {
    width: 960px;
    height: 480px;
    border: solid 3px var(--black);
    overflow: hidden;
    margin: auto;
    position: relative;
    box-sizing: border-box;
}

.preloader {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #FFD23C;
    z-index: 10;
    color: #000;
    font-size: 24px;
    text-align: center;
}

.preloader .loading {
    padding-top: 330px;
}

.preloader::before {
    display: block;
    position: absolute;
    width: 120px;
    height: 120px;
    top: 50%;
    left: 50%;
    margin: -60px 0 0 -60px;
    content: '';
    background: url('../images/loading_ammonite.png') no-repeat 50% 40%;
    background-size: 100%;
    animation: rotate 1s infinite;
    animation-timing-function: ease-in-out;
}

@keyframes rotate {
    0% {
        transform: rotate(0);
    }

    100% {
        transform: rotate(360deg);
    }
}

#rocks {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 200%;
    background: url('../images/bg-rock.jpg') repeat-y;
    background-size: 100%;
    z-index: 1;
}

#panels,
.panel {
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 2;
}

.gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/bg-x-pattern.png') repeat-x;
    background-size: auto 100%;
    z-index: 1;
}

.panel_content {
    position: relative;
    z-index: 2;
    width: 100%;
}

.flex {
    display: flex;
    justify-content: center;
    align-content: center;
}

.flex-item {
    margin: auto;
}

.hide {
    display: none;
}

button {
    border: none;
    background: none;
    margin: 0;
    padding: 0;
}

button:hover {
    cursor: pointer;
}

button:focus {
    outline: none;
}

/* splash panel */
#logo {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/layers-of-time-title.png') no-repeat 50% 30%;
    background-size: 390px;
}

#play {
    position: relative;
    top: 70%;
    display: block !important;
    margin: auto;
}

.orangeBtn {
    width: 250px;
    height: 60px;
    line-height: 60px;
    background: url('../images/button-sprite.png') no-repeat left top;
    background-size: 100% 200%;
    overflow: hidden;
    font-family: Skranji, sans-serif;
    font-size: 20px;
    color: #000;
}

.orangeBtn:hover {
    background-position: left bottom;
}

/* level panel */
#levels {
    text-align: center;
    background: url('../images/bg-x-pattern.png') repeat;
    border: solid 2px #000;
    width: 60%;
}

#levels>.inner {
    margin: 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.9);
}

#levels .title {
    font-size: 34px;
    padding-bottom: 15px;
}

#level_panel .level {
    width: 242px;
    height: 51px;
    line-height: 51px;
    margin: 5px 0;
    font-size: 30px;
    background: url('../images/menu-hover.png') no-repeat 50% 50%;
    background-size: 0;
}

#level_panel .level:hover {
    background-size: 100%;
    color: var(--blue_dark);
}

#volume {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 35px;
    height: 30px;
    background: url('../images/sound-sprite.png') no-repeat left top;
    background-size: 100%;
    z-index: 20;
}

/* game panel */
#sidebar_wrapper {
    position: absolute;
    top: 0;
    right: 0;
    width: 205px;
    height: 100%;
    z-index: 2;
}

.level_label {
    margin: 10px 0 15px;
    height: 35px;
    line-height: 35px;
    font-size: 16px;
}

#level_menu {
    padding-left: 30px;
    background: url('../images/up-arrow.png') no-repeat left 45%;
    background-size: 18px;
}

#level_label {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0.6;
    z-index: 2;
    text-transform: uppercase;
    margin-left: 9px;
    color: #d0e4ed;
}

#sidebar {
    width: 205px;
    height: 340px;
    margin-bottom: 12px;
    background: url('../images/sidebar.png') no-repeat;
    background-size: auto 100%;
    overflow: hidden;
    position: relative;
    left: 205px;
}

#sidebar #slider {
    width: 615px;
    position: relative;
    left: -205px;
}

#slider .slide {
    float: left;
    width: 175px;
    padding: 15px;
}

#sidebar .header {
    font-size: 24px;
    line-height: 1.25;
    padding: 7px 70px 0 0;
    min-height: 80px;
    position: relative;
}

#sidebar .header::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 64px;
    height: 77px;
    background: url('../images/sterling_head_circle.png') no-repeat top left;
    background-size: 100%;
}

#sidebar .header.rotate::before {
    animation: upsidedown 3s linear infinite;
    animation-direction: alternate;
    animation-timing-function: ease-in-out;
}

@keyframes upsidedown {
    0% {
        transform: rotate(180deg);
    }

    25% {
        transform: rotate(180deg);
    }

    50% {
        transform: rotate(0);
    }

    100% {
        transform: rotate(0);
    }
}

#need_a_hint {
    display: block;
    font-size: 18px;
    margin: 20px 0 0;
    padding: 0 20px 0 0;
    position: relative;
}

#need_a_hint .refresh {
    position: absolute;
    top: 4px;
    right: 0;
    width: 14px;
    height: 14px;
    background: url('../images/refresh.png') no-repeat top left;
    background-size: 100%;
}

#need_a_hint.clicked .refresh {
    animation: flip .5s linear;
    animation-timing-function: ease-in-out;
}

@keyframes flip {
    0% {
        transform: rotate(0);
    }

    100% {
        transform: rotate(180deg);
    }
}

#sidebar_correct .header {
    background: linear-gradient(to right, #6666ff, #d23be7, #e6261f, #eb7532, #84BD43, #6666ff, #d23be7, #e6261f);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: rainbow_animation 1s linear infinite;
    background-size: 400% 100%;
    -webkit-text-stroke: 1px #000;
    font-size: 32px;
    letter-spacing: 2px;
    line-height: 1.15;
}

@keyframes rainbow_animation {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 100% 0;
    }
}

#sidebar_correct p {
    margin: 14px 0;
}

#sidebar_correct .text {
    margin-top: 0;
    padding-top: 30px;
    background: url('../images/starline.gif') no-repeat top left;
    background-size: 100%;
}

#sidebar_wrapper .orangeBtn {
    width: 175px;
    height: 42px;
    line-height: 42px;
}

#check {
    position: relative;
    letter-spacing: -0.5px;
}

#layers_wrapper {
    height: 100%;
    background: url('../images/timeline.png') no-repeat 10px 60px;
    background-size: auto 390px;
}

#layers_wrapper>.inner {
    width: 700px;
    padding: 5px 0 0 36px;
}

#labels {
    height: 65px;
    position: relative;
    margin-bottom: 10px;
}

.label {
    position: absolute;
    bottom: 20px;
    width: 60px;
    transform: rotate(-30deg);
    font-size: 13px;
    line-height: 1;
    color: #fff;
    text-align: left;
}

#layers {
    position: relative;
    padding-left: 8px;
}

.layer,
.placeholder {
    left: 0;
    margin: -3px 0 0;
    height: 56px;
    position: relative;
    background: url('../images/layer-sprites.png') no-repeat 0 100%;
    background-size: 100% 300%;
}

.placeholder {
    background-image: url('../images/layer-shadow.png');
    background-size: 100% 100%;
}

.oldest_layer {
    background-image: url('../images/oldest-layer-sprites.png');
}

.oldest_layer.highlight::before {
    content: " ";
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 2;
    background: url('../images/green-layer.png') no-repeat top left;
    background-size: 100%;
}

/* hover must be disabled when checking order */
.can_hover:active {
    background-position: 0 50%;
    top: 1px !important;
    left: -2px !important;
}

/* only if hover supported (avoids "sticky" hover on touch devices) */
@media (hover: hover) {
    .can_hover:hover {
        cursor: grab;
        background-position: 0 50%;
        top: 1px !important;
        left: -2px !important;
    }
}

.layer.ui-sortable-helper {
    background-position: 0 0;
    cursor: grabbing;
}

.layer_name {
    background: rgba(0, 0, 0, 0.5);
    font-size: 28px;
    height: 100%;
    line-height: 67px;
    text-align: center;
    position: relative;
    z-index: 10;
    text-shadow: 0 0 2px #000;
    letter-spacing: 1px;
}

.item {
    position: absolute;
    top: 0;
    width: 53px;
    height: 53px;
    box-sizing: border-box;
    /* pointer-events:none; */
}

.amm {
    background-image: url('../images/fossils/amm.png');
}

.bir {
    background-image: url('../images/fossils/bir.png');
}

.cha {
    background-image: url('../images/fossils/cha.png');
}

.coc {
    background-image: url('../images/fossils/coc.png');
}

.coe {
    background-image: url('../images/fossils/coe.png');
}

.col {
    background-image: url('../images/fossils/col.png');
}

.con {
    background-image: url('../images/fossils/con.png');
}

.dic {
    background-image: url('../images/fossils/dic.png');
}

.dip {
    background-image: url('../images/fossils/dip.png');
}

.dra {
    background-image: url('../images/fossils/dra.png');
}

.dyr {
    background-image: url('../images/fossils/dyr.png');
}

.eff {
    background-image: url('../images/fossils/eff.png');
}

.flo {
    background-image: url('../images/fossils/flo.png');
}

.gin {
    background-image: url('../images/fossils/gin.png');
}

.hom {
    background-image: url('../images/fossils/hom.png');
}

.hor {
    background-image: url('../images/fossils/hor.png');
}

.ict {
    background-image: url('../images/fossils/ict.png');
}

.mol {
    background-image: url('../images/fossils/mol.png');
}

.mul {
    background-image: url('../images/fossils/mul.png');
}

.pos {
    background-image: url('../images/fossils/pos.png');
}

.pro {
    background-image: url('../images/fossils/pro.png');
}

.pte {
    background-image: url('../images/fossils/pte.png');
}

.rud {
    background-image: url('../images/fossils/rud.png');
}

.rug {
    background-image: url('../images/fossils/rug.png');
}

.sau {
    background-image: url('../images/fossils/sau.png');
}

.sei {
    background-image: url('../images/fossils/sei.png');
}

.sha {
    background-image: url('../images/fossils/sha.png');
}

.tar {
    background-image: url('../images/fossils/tar.png');
}

.tri {
    background-image: url('../images/fossils/tri.png');
}

/* red highlight is always a single circle */
.highlight_red {
    background-color: var(--red);
    border: solid 1px var(--red_dark);
    border-radius: 100%;
}

/* highlight top/bottom/square only for green */
.highlight_round,
.highlight_top,
.highlight_bottom,
.highlight_square {
    background-color: var(--green_lite);
    border: 5px solid var(--green);
}

.highlight_top {
    border-bottom: none;
    border-top-left-radius: 100%;
    border-top-right-radius: 100%;
}

.highlight_bottom {
    border-top: none;
    border-bottom-left-radius: 100%;
    border-bottom-right-radius: 100%;
}

.highlight_square {
    border-top: none;
    border-bottom: none;
}

.highlight_round {
    border-radius: 100%;
}

.fossil {
    width: 100%;
    height: 100%;
    background-position: 50% 50%;
    background-size: 90%;
    background-repeat: no-repeat;
}

#fossil_info {
    position: absolute;
    width: 370px;
    z-index: 10;
}

#fossil_info>.inner {
    background: #fff;
    padding: 14px;
    border: solid 2px #000;
    box-shadow: 3px -3px 0 rgba(0, 0, 0, 0.3);
    min-height: 125px;
    position: relative;
}

#fossil_info .pointer {
    background-size: 100%;
    position: absolute;
    width: 31px;
    height: 31px;
    z-index: 2;
}

#fossil_info.top_half>.inner {
    margin: 30px 0 0;
}

#fossil_info.bottom_half>.inner {
    margin: 0 0 30px;
}

.top_half .pointer {
    background: url('../images/speech-bubble-top.png');
    top: 1px;
}

.bottom_half .pointer {
    background: url('../images/speech-bubble-bottom.png');
    bottom: 1px;
}

.left_half .pointer {
    left: 60px;
}

.right_half .pointer {
    right: 60px;
}

#fossil_info .pointer {
    background-position: 0 0;
    background-size: 100%;
}

#fossil_info img {
    background-size: 100%;
    width: 100px;
    height: 125px;
    float: left;
    background-color: var(--red_lite);
}

#fossil_info .header {
    font-size: 24px;
    margin-bottom: 2px;
    text-transform: capitalize;
}

#fossil_info .header,
#fossil_info .text {
    margin-left: 110px;
}

#fossil_info a {
    color: var(--green);
}

#fossil_tool_tip {
    background: #fff;
    border: solid 1px #000;
    border-radius: 7px;
    color: #369;
    font-weight: bold;
    padding: 3px 6px;
    position: absolute;
    z-index: 3;
}

.close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 22px;
    height: 22px;
    background: url('../images/x.png') no-repeat 0 0;
    background-size: 100%;
    z-index: 3;
}

.tab:focus {
    outline: none;
}

.btn:hover {
    cursor: pointer;
}