canvas#siedler_board {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.bg.lumber {
    background-image: url('../images/terrains/forest.jpg') !important;
}
.bg.brick {
    background-image: url('../images/terrains/hills.jpg') !important;
}
.bg.wool {
    background-image: url('../images/terrains/pasture.jpg') !important;
}
.bg.grain {
    background-image: url('../images/terrains/fields.jpg') !important;
}
.bg.ore {
    background-image: url('../images/terrains/mountains.jpg') !important;
}

/* resources icons */

.icon.generic:before {
    background-image: url('../images/resources/generic.png');
    border-color: black;
}
.icon.lumber:before {
    background-image: url('../images/resources/lumber.png');
    border-color: darkgreen;
}
.icon.brick:before {
    background-image: url('../images/resources/brick.png');
    border-color: darkred;
}
.icon.wool:before {
    background-image: url('../images/resources/wool.png');
    border-color: lightgreen;
}
.icon.grain:before {
    background-image: url('../images/resources/grain.png');
    border-color: goldenrod;
}
.icon.ore:before {
    background-image: url('../images/resources/ore.png');
    border-color: darkgray;
}

/* info icons */

.icon.knights:before, .icon.road_max:before, .icon.resources:before, .icon.cards:before, .icon.trophy:before, .icon.hexagon:before {
    background-image: url('../images/symbols/knights.png');
    border-color: transparent;
    background-color: transparent;
}
.icon.gold:before {
    border-color: orange;
}
.icon.road_max:before {
    background-image: url('../images/symbols/road_max.png');
}
.icon.resources:before {
    background-image: url('../images/symbols/resources.png');
}
.icon.cards:before {
    background-image: url('../images/symbols/cards.png');
}
.icon.trophy:before {
    background-image: url('../images/symbols/trophy.png');
}
.icon.hexagon:before {
    background-image: url('../images/symbols/hexagon.png');
}

/* development card */

div.card:before {
    content: attr(title);
    font-weight: bold;
    display: block;
    text-align: center;
    font-size: 0.8em;
    color: white;
    background: gray;
}
div.card.progress:before {
    background-color: darkgreen;
}
div.card.knight:before {
    background-color: purple;
}
div.card.victory_point:before {
    background-color: darkgoldenrod;
}

div.card {
    background: ivory;
    border-radius: 7px;
    border: 3px solid lightgray;
    box-shadow: 2px 2px 15px rgba(0,0,0,0.4);
    display: inline-block;
    height: 12em;
    width: 7em;
    color: black;
    vertical-align: top;
}

div.card div {
    font-style: italic;
    text-align: center;
}

div.card.clickable {
    cursor: pointer;
}

.person div.card {
    position: relative;
    bottom: 60%;
    font-size: 0.8em;
    z-index: 9999;
}

div.card.clickable:hover {
    border-color: black;
}

div.card div {
    font-size: 0.65em;

}

div.card .pic {
    display: inline-block;
    width: 100%;
    height: 50%;
    background-size: cover;
    background-position: center;
}

div.card h1 {
    font-size: 2.5em;
    font-weight: normal;
    font-style: normal;
}

/* card end */

.icon {
    display: inline-block;
    width: 20%;
    font-weight: bold;
    font-size: 1.2em;
    background-size: cover;
    background-position: center;
    color: white;
    padding: 3px;
    border-radius: 3px;
}

div#dialog .icon {
    font-size: 1.5em;
}

.icon:before {
    content: '';
    width: 1em;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    height: 1em;
    padding: 2px;
    background-color: rgba(255,255,255,0.8);
    display: inline-block;
    border-radius: 100%;
    border: 2px solid black;
}

div#storageDlg .change {
    font-weight: bold;
    background-color: rgba(220,220,220,0.6);
}

div#dialog div#storageDlg .icon {
    font-size: 1.2em;
}

div#dialog div.icon {
    width: auto;
}

div.storage {
    border-bottom: 3px solid;
    border-color: inherit;
}

div.dice {
    display: inline-block;
    width: 2em;
    height: 2em;
    margin: 3px;
    border: 3px groove white;
    background-size: cover;
    background-repeat: no-repeat;
    position: relative;
    z-index: 99;
}

div.dice.one {
    transform: rotate(29deg);
}

div.dice.two {
    transform: rotate(-17deg);
}

body.playing div.person.myself.active div.info {
    display: none;
}

div.banner {
    position: absolute;
    z-index: 10000;
    width: 100%;
    bottom: 100%;
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none; /* Safari */
    -ms-user-select: none; /* IE 10 and IE 11 */
    text-align: right;
}

div.person.right div.banner {
    text-align: left;
}

div.popup {
    position: relative;
    animation: dissolve 6s cubic-bezier(0, 0, 0.2, 1) 1;
    opacity: 0;
    height: 0;
    margin-bottom: 0.2em;
    white-space: nowrap;
}
div.popup .icon {
    white-space: nowrap;
    display: inline-block;
    width: auto;
    font-size: 0.85em;
}

/* price info dialog */

div.structure {
    display: block;
    text-align: left;
    font-weight: bold;
    border-bottom: 0.15em solid black;
    width: 40em;
    max-width: 100vw;
}

div.structure > * {
    vertical-align: middle;
}

div.structure svg {
    margin: 0 1em;
    width: 3em;
    display: inline-block;
    text-align: center;
}

div.structure h2 {
    display: inline-block;
    font-family: 'Playfair Display';
    width: 40%;
    margin: 0;
    text-shadow: none;
}

div.structure div.price {
    display: inline-block;
    width: 30%;
}

/* mouse action menu */

div#point_action:before {
    content: 'Action';
    display: block;
    background: white;
    color: black;
}

div#point_action {
    display: none;
    position: fixed;
    z-index: 999;
    width: auto;
    height: auto;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    border: 3px solid white;
    border-radius: 3px;
}

div#point_action div.structure {
    cursor: pointer;
    width: auto;
    border-color: white;
}

div#point_action div.structure:hover {
    background: white;
    color: black;
}

div#point_action h2,
div#point_action div.price,
div#point_action div.icon {
    width: auto;
}

div#point_action div.structure#move_ship {
    display: block;
}

body.free-build div#point_action div.price {
    display: none;
}

@keyframes dissolve {
    0%, 50% {
        opacity: 1;
        height: 1.5em;
    }

    75% {
        opacity: 0;
        height: 1.5em;
    }

    100% {
        opacity: 0;
        height: 0;
    }
}
