* { margin:0; padding:0; }

#hangman {
    position: relative;
    height: 600px;
    width: 375px;
    font-family: arial;
    margin: 2px;
}

#hangman .gallow.top {
    position: absolute;
    top: 10px;
    left: 0px;
    width: 170px;
    height: 5px;
    background-color: #000;
}

#hangman .gallow.body {
    position: absolute;
    top: 15px;
    left: 0px;
    width: 385px;
    height: 356px;
    border-left: 5px solid #000;
}

#hangman .gallow.body .timer {
    position: absolute;
    bottom: 47px;
    left: 20px;
    font-size: 29px;
    z-index: 3;
    color: lightgrey;
}

#hangman .gallow.body .letters {
    position: absolute;
    left: 23px;
    bottom: 22px;
    width: 385px;
    white-space: nowrap;
    overflow: visible;
}
#hangman .gallow.body .letters .char {
    display: inline-block;
    margin-right: 5px;
    width: 10px;
    font-size: 14px;
    text-align: center;
}

#hangman .gallow.bottom { 
    position: absolute;
    left: 0;
    right: 0;
    bottom: 224px;
    height: 5px;
    background-color: #000;
}

#hangman .hint {
    position: absolute;
    top: 0px;
    right: 0px;
    width: 193px;
    max-height: 305px;
    overflow: auto;
    padding: 5px;
    text-align: center;
    font-size: 12px;
    color: #000;
    background-color: lightgrey;
    border: 1px solid #000;
}
#hangman .hint-text {
    padding-top: 10px;
    padding-bottom: 10px;
    display: inline-block;
}

#hangman .abc {
    position: absolute;
    bottom: 135px;
    left: 0px;
    width: 380px;
}
#hangman .abc.letters .char,
#hangman.gameover .abc.letters .char:hover {
    margin-bottom: 5px;
    margin-right: 4px;
    border: 1px solid #000;
    padding: 3px;
    display: inline-block;
    text-align: center;
    width: 17px;
    font-size: 13px;
    background-color: transparent;
    color: #000;
}
#hangman.gameover .abc.letters .char:hover {
    cursor: default;
}
#hangman .abc.letters .char span {
    display: block;
    text-align: center;
}
#hangman .abc.letters .char:hover {
    border-color: green;
    background-color: green;
    color: #fff;
    cursor: pointer;
}
#hangman .abc.letters .char.used,
#hangman .abc.letters .char.used:hover {
    cursor: default;
    border-color: #000;
    background-color: transparent;
    color: #000;
}
#hangman .abc.letters .char.correct,
#hangman .abc.letters .char.correct:hover {
    border-color: green;
    background-color: green;
    color: #fff;
}

#hangman .letters .char {
    font-size: 12px;
    font-weight: bold;
    border-bottom: 1px solid #000;
    width: 12px;
    padding-right: 5px;
    padding-bottom: 2px;
    color: #000;
}
#hangman .letters .char:last-child {
    margin-right: 0;
}
#hangman .letters .char.correct {
    color: green;
}
#hangman .letters .char.incorrect {
    text-decoration: line-through;
    opacity: .25;
}
#hangman .letters .char.non-alpha {
    border: 0;
}

#hangman.gameover .hanging .gameover-image {
    display: block;
    position: absolute;
    z-index: 3;
    top: 86px;
    left: 10px;
    width: 190px;
    height: 143px;
    background-image: url('./img/game-over.png');
    background-size: contain;
    background-position: center center;
    background-repeat: no-repeat;
    cursor: pointer;
}
#hangman.gameover.winner .hanging .gameover-image {
    background-image: url('./img/winner.png');
    top: 79px;
    left: 10px;
}

#hangman .tries-1 .hanging .noose,
#hangman .tries-2 .hanging .noose,
#hangman .tries-3 .hanging .noose,
#hangman .tries-4 .hanging .noose,
#hangman .tries-5 .hanging .noose,
#hangman .tries-6 .hanging .noose,
#hangman .tries-7 .hanging .noose {
    display: block;
    position: absolute;
    z-index: 0;
    top: 0px;
    left: 43px;
    background-image: url('./img/noose.jpg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: top center;
    width: 75px;
    height: 75px;
}

#hangman .hanging .skeleton {
    display: none;
    position: absolute;
    z-index: 1;
    left: 34px;
    top: 39px;
    width: 87px;
    height: 250px;
    background-image: url('./img/skeleton.png');
    background-position: top center;
    background-size: contain;
    background-repeat: no-repeat;
}
#hangman .hanging .skeleton .cover {
    display: none;
    position: absolute;
    background-color: #fff;
}
#hangman .tries-2 .hanging .skeleton {
    display: block;
    /*clip: rect(0px, 0px, 430px, 0px);*/
    clip-path: inset(0px 0px 215px 0px);
}
#hangman .tries-3 .hanging .skeleton {
    display: block;
    /*clip: rect(0px, 45px, 198px, 50px);*/
    clip-path: inset(0px 22px 99px 25px);
}
#hangman .tries-4 .hanging .skeleton {
    display: block;
    /*clip: rect(0px, 45px, 198px, 0);*/
    clip-path: inset(0px 22px 99px 0);
}
#hangman .tries-5 .hanging .skeleton {
    display: block;
    /*clip: rect(0px, 0px, 198px, 0);*/
    clip-path: inset(0px 0 99px 0);
}
#hangman .tries-6 .hanging .skeleton {
    display: block;
}
#hangman .tries-6 .hanging .skeleton .cover {
    display: block;
    bottom: 0;
    right: 0;
    width: 37px;
    height: 99px;
}
#hangman .tries-7 .hanging .skeleton {
    display: block;
}

#hangman .info {
    position: absolute;
    bottom: 55px;
}
#hangman .info .category .value {
    color: green;
    text-decoration: underline;
    cursor: pointer;
}

#hangman .menu {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    font-size: 17px;
}
#hangman .menu .skip-word {
    position: absolute;
    right: 0;
    cursor: pointer;
    color: green;
    text-decoration: underline;
}
#hangman .menu .custom-game {
    position: absolute;
    left: 0;
    cursor: pointer;
    color: green;
    text-decoration: underline;
}
#hangman .menu .auto-play {
    position: absolute;
    left: 153px;
    cursor: pointer;
    color: green;
    text-decoration: underline;
}