
@font-face {
    font-family: 'superclarendonx';
    src: url('../images/superclarendonx.otf') format('truetype');
}

html {
    font-size: 12px;
}

body {
    background-color: #000;
    color: #fff;
    margin: 0;
    padding: 0;
}

* {
    box-sizing: content-box;
}

#alamo-app {
    xmargin: 4rem auto;
    font-size: 2rem;
    xborder-radius: 1.5rem;
    overflow: hidden;
    width: 100rem;
    height: 56rem;
    display: block;
    position: relative;
    font-family: superclarendonx;

    xborder: solid 1px #222;
}

img, div {
    display: block;
    position: relative;
}

.sprite {
    position: absolute;
    top: 0;
    left: 0;
    overflow: hidden;
}

.sprite img {
    position: absolute;
    height: 100%;
}

.layer {
    position: absolute;
    width: 100%;
    height: 100%;
    height: 0;
    left: 0;
    top: 0;
}

.layer-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
}

.hide {
    display: none;
}

.font-load {
    display: none;
    font-family: ScienceFair;
}


img {
    pointer-events: none;
}

* {
    user-select: none;
}

.popup {
    position: absolute;
    background-color: #000;
    border: solid 0.4rem #081b4f;
    border-radius: 0.8rem;
    height: 40rem;
    width: 60rem;
    top: 10rem;
    left: 20rem;
    display: none;
    box-shadow: 0 0 10rem #000;
}


/*-----------------------*/


#right-shade {
    position: absolute;
    right: 0;
    width: 25rem;
    height: 100%;
    background: linear-gradient(90deg,rgba(70,40,24, 0) 0%, rgba(70,40,24, 0.5) 100%);
    z-index: 1;
    display: none;
}

#layer-cards {
    top: 7rem;
    left: 82rem;
    width: 16rem;
    z-index: 4;
}

#layer-ui {
    z-index: 3;
}

#ui-turn {
  position: absolute;
  right: 2rem;
  bottom: 2.5rem;
  color: #fff;
  font-size: 80%;
  text-align: center;
  width: 16rem;
  text-shadow: 0 0 2rem rgb(0, 0, 0);
}

#ui-pick-3 {
    position: absolute;
    right: 2rem;
    top: 2rem;
    color: #eee;
    font-size: 90%;
    background-color: #745a2e;
    border-radius: 0.5rem;
    padding: 1rem 0;
    width: 16rem;
    text-align: center;
    box-shadow: 0 0 2rem rgba(255,255,255,0.2);
}

#ui-pick-3 span {
    opacity: 1;
    transition: all 200ms;
}

#ui-pick-3 span.fade {
    opacity: 0.5;
}

#ui-pick-3.done {
    background-color: #61782e;
    color: #fff;
    cursor: pointer;
    border-bottom: solid 2px #4c5a2d;
    box-shadow: 0 0 16px rgba(255,255,255,0.5);
    text-shadow: 0 0 6px rgba(0,0,0,0.4);
}
#ui-pick-3.done:hover {
    box-shadow: 0 0 16px rgba(255,255,255,0.8);
    background-color: #6a8137;
}

#layer-tex {

}


.tex {
    width: 3.5rem;
    position: absolute;
    display: none;
    transition: translate 600ms, scale 600ms;
    z-index: 2;
}

.tex.alive {
    display: block;
}

.deadspot {
    position: absolute;
    z-index: 1;
    width: 0.5rem;
    height: 0.5rem;
    margin-left: 1.5rem;
    margin-top: 1.5rem;
    background-color: #ae9a78;
    border-radius: 50%;
    background-color: #352e23;
    border-radius: 50%;
    opacity: 0.18;
}



.mex-army {
    position: absolute;
    width: 28rem;
    height: 36rem;
    text-align: center;
    display: flex;
}

.mex-army img {
    width: 3.8rem;
    height: 3.8rem;
    display: inline-block;
    filter: drop-shadow(0 0 16px rgba(255,255,255,0.8));
}

.mex-army.danger img {
    filter: drop-shadow(0 0 3px rgba(255,0,0,0.5));
}

.mex-army img.hit {
    z-index: 10;
}

.mex-army.dir-l  {
    top: 9rem;
    left: 2rem;
    width: 6rem;
    flex-flow: column wrap-reverse;
    justify-content: center;
}

.mex-army.dir-r {
    top: 10rem;
    left: 72rem;
    width: 6rem;
    flex-flow: column wrap;
    justify-content: center;
}

.mex-army.dir-u {
    top: 0rem;
    left: 17rem;
    height: 9rem;
    width: 40rem;
    align-items: center;
    justify-content: center;
}

.mex-army.dir-d {
    top: 47.5rem;
    left: 20rem;
    height: 8rem;
    width: 40rem;
    align-items: center;
    justify-content: center;
}




.mex-army.dir-l img, .mex-army.dir-r img {
    margin-right: -1rem;
    margin-bottom: -2rem;
}

.mex-army.dir-u img, .mex-army.dir-d img {
    align-items: center;
    margin-right: -2.3rem;
    margin-bottom: 0rem;
}

.mex-army.dir-l img:nth-child(5n),
.mex-army.dir-r img:nth-child(5n) {
    margin-bottom: 1rem;
}

.mex-army.dir-u img:nth-child(5n),
.mex-army.dir-d img:nth-child(5n) {
    margin-right: -0.5rem;
}



.card {
    width: 16rem;
    height: 8rem;
    margin-bottom: 0.4rem;
    position: relative;
    z-index: 1;
    left: 0;
    overflow: hidden;
    border-radius: 1rem;
    border: solid 2px transparent;
    border-bottom: solid 2px #666;
    transition: opacity 200ms, left 100ms;
}

.card:hover {
    box-shadow: 0 0 0.75rem rgb(0,0,0, 0.5);
    border: solid 2px #fff;
    cursor: pointer;
}

.card.used:hover {
    box-shadow: none;
    border: solid 2px transparent;
    border-bottom: solid 2px #666;
    cursor: default;
}

.card.in-progress {
    box-shadow: 0 0 0.75rem rgb(231, 150, 64);
    border: solid 2px #d19353;
    xleft: -1rem;
    z-index: 2;
    filter: brightness(1.03);
}

.card.used {
    opacity: 0.3;
}

.card.used:hover {
    box-shadow: none;
    cursor: default;
}

.full-img img {
    width: 100%;
    position: absolute;
    top: 0;
    left: 0;
}



.info-button {
    background-color: #229;
    color: #fff;
    padding: 1.2rem;
    font-size: 1.8rem;
    text-align: center;
    position: relative;
    margin-bottom: 0.4rem;
    border-radius: 0.8rem;
}


.icon-factory {
    top: 3rem;
    left: -0.5rem;
}

.icon-spy {
    top: -1rem;
    left: -0.5rem;
}

#layer-ui {
    width: 100%;
    height: 100%;
    display: none;
}

#layer-chars {
    z-index: 4;
}

#layer-chars .sprite {
    cursor: pointer;
}

#layer-chars .sprite:hover {
    scale: 1.08;
}

.char-crockett {
    top: 24rem;
    left: 51rem;
}

.char-travis {
    top: 30rem;
    left: 20rem;
}

.char-bowie, .char-bowie.dir-u {
    top: 13.5rem;
    left: 39rem;
    transition: left 1000ms, top 1000ms;
}

.char-bowie.dir-r {
    top: 34rem;
    left: 55rem;
}
.char-bowie.dir-d {
    top: 35rem;
    left: 36rem;
}
.char-bowie.dir-l {
    top: 25rem;
    left: 20rem;
}

.char-bigcannon {
    top: 35.5rem;
    left: 46.6rem;
}

.char-travis img { left: -100%; }
.char-bowie img { left: -200%; }
.char-bigcannon img { left: -300%; }



#instructions {
    margin: 4rem auto;
    width: 100rem;
    box-sizing: border-box;
    padding: 1rem 4rem;
    line-height: 1.6;
    font-family: superclarendonx;
    color: #eee;
    font-size: 18px;
}

h2 {
    margin-top: 3rem;
    color: #dfa53c;
}

#splash {
    display: none;
    position: absolute;
    z-index: 10;
    width: 27.0rem;
    top: 5.0rem;
    right: 6.4rem;
    cursor: pointer;
    pointer-events: all;
}

.winlose {
    position: absolute;
    z-index: 100;
    top: 15rem;
    left: 18rem;
    width: 40rem;
    padding: 1.5rem 2rem 2rem 2rem;
    border-radius: 2rem;
    overflow: hidden;
    background-color: #3f3522;
    text-align: center;
    color: #fff;
    font-size: 1.5rem;
    line-height: 1.7;
    box-shadow: 0 0 2rem rgba(0,0,0, 0.8);
    border: solid 2px #b8aa8f;
    text-shadow: 0 0 16px rgba(0,0,0,0.25);
}

#win .winlose-title {
    color: #ffc049;
}

#lose .winlose-title {
    color: #da5d56;
}

.winlose img {
    width: 50%;
    display: inline-block;
    filter: drop-shadow(0 0 12px rgba(0,0,0,0.5));
}

#win, #lose {
    display: none;
}

.winlose-title {
    font-size: 2.8rem;
    margin-top: -1rem;
    text-transform: uppercase;
}

.winlose-score {
    margin-top: 0.8rem;
}



#modal {
    display: none;
    width: 40rem;
    background-color: #7d6536;
    border-radius: 1rem;
    border: solid 2px #52401d;
    position: absolute;
    left: 30rem;
    top: 17rem;
    font-size: 1.4rem;
    line-height: 1.5;
    z-index: 20;
    box-shadow: 0 0 2rem rgba(0,0,0,0.5);
}

#modal-title {
    padding: 0.5rem 0;
    text-align: center;
    font-weight: bold;
    background-color: #52401d;
    border-radius: 1rem 1rem 0 0;
    text-transform: uppercase;
}

#modal-body {
    padding: 1.5rem;
    min-height: 5rem;
}

#modal-buttons {
    width: 100%;
    border-top: solid 1px #52401d;
    cursor: pointer;
}

.modal-button {
    display: inline-block;
    text-align: center;
    padding: 0.5rem 0;
    margin: 0;
}

.modal-button:hover {
    background-color: #9e7c3a;
}

#modal-button-action {
    width: 24.9rem;
    border-left: solid 1px #52401d;
    border-radius: 0 0 1rem 0;
}

#modal-button-cancel {
    width: 15rem;
    border-radius: 0 0 0 1rem;
}

#modal-buttons.modal-alert #modal-button-action {
    display: none;
}

#modal-buttons.modal-alert #modal-button-cancel {
    width: 100%;
}

#modal-body p:first-child {
    margin-top: 0;
}

.dir-buttons {
    text-align: center;
    margin-top: 1rem;
}

.button-dir {
    display: inline-block;
    margin: 0 0.5rem;
    cursor: pointer;
    border: solid 1px #333;
    padding: 0.1rem 0.5rem;
    width: 6rem;
    border-radius: 0.5rem;
    text-align: center;
}

.button-dir.selected {
    background-color: #382e1d;
}

img.miss {
    position: absolute;
    width: 4rem;
    height: 4rem;
}

.miss.dir-u {
    top: 3rem;
    left: 38.8rem;
}

.miss.dir-d {
  top: 49.4rem;
  left: 37.7rem;
}

.miss.dir-l {
    left: 4.6rem;
    top: 28rem;
}

.miss.dir-r {
    left: 72rem;
    top: 25rem;
}


