html {
    height: 100%;
    width: 100%;
}

body {
    font-size: 18pt;
    background: url('../img/wood_pattern.png') repeat;
    height: 100%;
    margin: 0;
    padding: 1em 0;
    position: absolute;
    text-align: center;
    width: 100%;
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

body > section {
    display: none;
}
body > .visible {
    display: block;
}

#ball-wrap {
    position: relative;
    min-height: 340px;
    width: 100%;
}

#ball {
    border-radius: 50%;
    background-image: -moz-radial-gradient(45px 45px 45deg, circle cover, #888 0%, #555 30%, #222 50%, black 95%);
    background-image: -webkit-radial-gradient(45px 45px, circle cover, #888, black);
    background-image: radial-gradient(45px 45px 45deg, circle cover, #888 0%, #555 30%, #222 50%, black 95%);
    display: inline-block;
    height: 300px;
    width: 300px;
}
#ball[data-mode=compliments] {
    background-image: -moz-radial-gradient(45px 45px 45deg, circle cover, yellow 0%, orange 80%, red 95%);
    background-image: -webkit-radial-gradient(45px 45px, circle cover, yellow, black);
    background-image: radial-gradient(45px 45px 45deg, circle cover, yellow 0%, orange 80%, red 95%);
}
#ball[data-mode=dollar] {
    background-image: -moz-radial-gradient(45px 45px 45deg, circle cover, #74DF00 0%, #4B8A08 80%, #38610B 95%);
    background-image: -webkit-radial-gradient(45px 45px, circle cover, #74DF00, #38610B);
    background-image: radial-gradient(45px 45px 45deg, circle cover, #74DF00 0%, #4B8A08 80%, #38610B 95%);
}

.inside-circle {
    border-radius: 50%;
    height: 180px;
    margin: 60px;
    position: absolute;
    width: 180px;
}

#eight {
    background-color: #fff;
    color: #000;
    font: 72pt monospace;
    line-height: 180px;
}
.back #eight {
    display: none;
}

#ball[data-mode=classic] #eight:before {
    content: '8';
}
#ball[data-mode=compliments] #eight:before {
    font: 120pt Arial sans-serif;
    line-height: 180px;
    content: '\263A';
}
#ball[data-mode=dollar] #eight:before {
    content: '$';
}

.shaking {
    -webkit-animation-direction: alternate;
    -webkit-animation-duration: .1s;
    -webkit-animation-iteration-count: infinite;
    -webkit-animation-name: shaking;
    -webkit-animation-timing-function: linear;
    animation-direction: alternate;
    animation-duration: .1s;
    animation-iteration-count: infinite;
    animation-name: shaking;
    animation-timing-function: linear;
}
@keyframes shaking {
    from {
        margin-left: 1em;
        margin-top: -1em;
    }
    to {
        margin-left: -1em;
        margin-top: 1em;
    }
}
@-webkit-keyframes shaking {
    from {
        margin-left: 1em;
        margin-top: -1em;
    }
    to {
        margin-left: -1em;
        margin-top: 1em;
    }
}

#result {
    background-color: #0A0A2A;
    border: #0B0B61 1px solid;
    display: none;
}
.back #result {
    display: block;
    border-radius: 50%;
}

#tria-wrap {
    opacity: 0;
    padding: 50px 10px;
}

#tria-wrap.show {
    opacity: 1;
    transition-property: opacity;
    transition-delay: 1s;
    transition-duration: 2s;
}

#triangle {
    height: 0;
    border-left: 80px solid transparent;
    border-right: 80px solid transparent;
    border-top: 120px solid #0404B4;
    font-size: 0;
    line-height: 0;
    position: absolute;
    width: 0;
}

#msg {
    -moz-box-sizing: border-box;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    color: #CECEF6;
    font: 12pt monospace;
    padding: 1em 2em;
    position: relative;
    text-align: center;
    text-transform: uppercase;
    width: 100%;
}

#info {
    border-radius: 50%;
    background-color: #666;
    color: #fff;

    font: 18pt Arial;
    font-weight: bold;
    text-decoration: none;
    vertical-align: middle;

    position: absolute;
    bottom: 10%;
    right: 5%;
    height: 2em;
    width: 2em;
    line-height: 2em;
}
#info:not(.settings):before {
    content: '\2699'; /* gear */
    font-size: 36pt;
}
#info.settings:before {
    content: '\21A9'; /* "back" */
}

#mode .button {
    margin-bottom: .5em;
}

#install {
    display: none;
}

.button {
    -moz-box-shadow: inset 0px 1px 0px 0px #fff;
    -webkit-box-shadow: inset 0px 1px 0px 0px #fff;
    box-shadow: inset 0px 1px 0px 0px #fff;
    background: -webkit-gradient( linear, left top, left bottom, color-stop(0.05, #fff), color-stop(1, #f6f6f6) );
    background: -moz-linear-gradient( center top, #fff 5%, #f6f6f6 100% );
    background-color: #fff;
    -moz-border-radius: 6px;
    -webkit-border-radius: 6px;
    border-radius: 6px;
    border: 1px solid #dcdcdc;
    display: inline-block;
    color: #666;
    font: 15px Arial;
    font-weight: bold;
    padding: 6px 24px;
    text-decoration: none;
    text-shadow: 1px 1px 0px #fff;
}
.button:hover {
    background: -webkit-gradient( linear, left top, left bottom, color-stop(0.05, #f6f6f6), color-stop(1, #fff) );
    background: -moz-linear-gradient( center top, #f6f6f6 5%, #fff 100% );
    background-color: #f6f6f6;
}
.button.selected {
    border: 4px solid #333;
}
