﻿/** General Style **/

.ui-container {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    
    /* below bootstrap modal */
    z-index: 900;
}

.force-visible {
    display: block !important;
}

.ui-landscape .not-landscape {
    display: none;
}

.ui-portrait .not-portrait {
    display: none;
}

.ui-embedded .standalone {
    display: none;
}

.ui-standalone .embedded {
    display: none;
}

/** Generic Button **/
.generic-btn {
    cursor: pointer;
    pointer-events: auto;
    position: absolute; 
    width: 32px; 
}
.generic-btn-withtext {
    display: flex;
    align-items: center;
}

.generic-btn-img {
    max-width: 100%;
    max-height: 100%;
}

.generic-btn img[src$=".svg"] {
    width:100%
}

/** Home Button **/

.home-btn {
    /* align to center */
    margin-left: -16px; 
    margin-top: -16px; 
}

.home-btn-img {
    width: 100%;
    display: block;
    height: auto;
}

/** Label **/

.lbl {
    position: absolute;
    font-family: Verdana, Geneva, sans-serif;
    font-size: 20px;
    font-weight: bold;
    color: white;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 1);

    /*show text align in middle*/
    display: flex;
    align-items:center;
}

/** SessionTime **/

.sessiontime-ctrl {
    color: #fff;
    text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000;
}

/** Bar **/

.bar-ctrl {
    position: absolute;
    background-color: #000;
    z-index: -50;
}

/** LongPress Bar **/

.bar-lp-ctrl {
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    user-select: none;
    position: absolute;
    pointer-events: auto;
    background-color: #212121;
    color: #a7a7a7;
    font-size: 10px;
    text-shadow: 0 4px 4px rgba(0, 0, 0, 0.25);
    text-align: center;
    white-space: nowrap;
    z-index: -50;
}

.bar-lp-ctrl-text {
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    user-select: none;
    display: flex;
    align-items: stretch;
}

.bar-lp-ctrl-info {
    background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTI4IiBoZWlnaHQ9IjEyOCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgo8cGF0aCBkPSJNMTEuOTk5IDhDMTEuODYxIDggMTEuNzQ5IDguMTEyIDExLjc1IDguMjVDMTEuNzUgOC4zODggMTEuODYyIDguNSAxMiA4LjVDMTIuMTM4IDguNSAxMi4yNSA4LjM4OCAxMi4yNSA4LjI1QzEyLjI1IDguMTEyIDEyLjEzOCA4IDExLjk5OSA4IiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNMTIgMjFWMjFDNy4wMjkgMjEgMyAxNi45NzEgMyAxMlYxMkMzIDcuMDI5IDcuMDI5IDMgMTIgM1YzQzE2Ljk3MSAzIDIxIDcuMDI5IDIxIDEyVjEyQzIxIDE2Ljk3MSAxNi45NzEgMjEgMTIgMjFaIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjEuNSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxwYXRoIGQ9Ik0xMiAxMlYxNyIgc3Ryb2tlPSJ3aGl0ZSIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPgo8L3N2Zz4K");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    width: 24px;
    margin-left: auto;
}

.bar-lp-ctrl-info-text {
    text-align: left;
    white-space: normal;
    background: inherit;
    position: absolute;
    width: 100%;
    display: none;
    padding: 8px 16px;
}

.bar-lp-ctrl-info-text.showed {
    display: block;
}

.bar-lp-ctrl-click {
    padding: 3px;
    margin: -3px;
    text-decoration: underline;
}

.bar-lp-ctrl-click.element-pressed {
    background-color: #555;
}

/** Uk Bar **/

.bar-uk-ctrl {
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    user-select: none;
    pointer-events: none;
    position: absolute;
    display: flex;
    background-color: #212121;
    color: #fff;
    font-size: 14px;
    padding: 3px 10px 0;
    z-index: -50;
}

.bar-uk-ctrl-text-element {
    white-space: nowrap;
}

.bar-uk-ctrl-text-element:nth-child(2n) {
    margin: 0 5px 0 2px;
}

/** CaOntario Bar **/

.bar-caontario-ctrl {
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    user-select: none;
    pointer-events: none;
    position: absolute;
    display: flex;
    background-color: #212121;
    color: #fff;
    font-size: 14px;
    padding: 3px 10px 0;
    z-index: -50;
}

.bar-caontario-ctrl-text-element {
    white-space: nowrap;
}

.bar-caontario-ctrl-text-element:nth-child(2n) {
    margin: 0 5px 0 2px;
}

/** Fullscreen Button **/
.fullscreen-btn {
    position: absolute;
    width: 32px;
    height: 32px;
    margin-left: -16px;
    margin-top: -16px;
    cursor: pointer;
    pointer-events: auto;
}
.fullscreen-btn img {
     width: 32px;
}
.fullscreen-btn.maximize .mx-img,
.fullscreen-btn.minimize .mn-img {
    display: block;
}
.fullscreen-btn.maximize .mn-img,
.fullscreen-btn.minimize .mx-img {
    display: none;
}

.fullscreen-hidden {
    display: none;
}

.blur-element {
    animation: game-blur 4s forwards;
    -webkit-animation: game-blur 4s forwards;
}
@keyframes game-blur {
    0% { filter: blur(0.5px); }
    100% { filter: blur(7px); }
}
@-webkit-keyframes game-blur {
    0% { filter: blur(0.5px); }
    100% { filter: blur(7px); }
}

/** Menu Button **/

.menu-button {
    background-color: #838383
}
.menu-button .hamburger {
    width: 38px;
    height: 0;
    margin: 7px 0;
    border-radius: 3px;
    border: 2px #fff solid;
}
.menu-button .icon-bar{
    background: #fff;
    display: block;
    height: 2px;
    margin: 0;
}
#menu-button-wrapper {
    pointer-events: auto;
}
#menu-button-wrapper .menu-button-image{
    width: 40px;
    cursor: pointer;
}
#menu-button-wrapper button{
    padding: 2px 5px;
}

/** Menu Top Panel **/

#menu-wrapper {
    transform: translate3d(0,0,0);
    display: block !important;
    pointer-events: auto;
    position: fixed;
}
#panel-wrapper {
    position: fixed;
    top: 0;
    left: -300px;
    width: 80vw;
    max-width: 300px;
    height: 100vh;
    overflow: hidden;
    transition: left 0.7s ease;
    background-color: #292828;
    z-index: 100;
}
.show:not(.external-menu) #panel-wrapper {
    left: 0;
}
#menu-wrapper .panel-logo {
    height: 32px;
    background-repeat: no-repeat;
    background-position: center;
    margin-bottom: 15px;
    margin-top: 15px;
}
#panel-header {
    margin-bottom: 15px;
}
.panel-list-item {
    margin-top: 0;
}

#panel-scroll {
    height: 100%;
    margin-right: -50px;
    overflow-y: scroll;
}

#panel-unscroll {
    /* same as panel wrapper */
    width: 80vw;
    max-width: 300px;
}
/** Game Overlay **/
.overlay-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    visibility: hidden;
    background-color: #000;
    opacity: 0;
    z-index: 50;
    transition: opacity 0.6s ease;
}
.show .overlay-background {
    visibility: visible;
    opacity: 0.6;
}
/** Menu Game Overlay **/
#game-overlay-wrapper .overlay-mock-menu {
    top: 0;
    left: 0;
    flex-shrink: 0;
    width: 80vw;
    max-width: 300px;
    height: 100%;
}
#overlay-label {
    display: none;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}
.show #overlay-label {
    display: flex;
}
.overlay-elements {
    z-index: 80;
    font-size: 28px;
    color: white;
    position: relative;
    width: auto;
    margin: 0 auto;
}

.overlay-label {
    width: 230px;
    text-align: center;
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
}

/** Menu Games Carousel **/

#panel-games {
    text-align: center;
}

.games-carousel {
    margin: 10px 0 15px 0;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
    overflow: hidden;
}

.game-link {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 5px;
}

.game-image {
    width: 70px;
    border-radius: 5px;
}

/** Menu Panel & Items List **/

.panel-button.btn-default {
    color: #fff;
    background: #212121;
    border-color: #555555;
    letter-spacing: 1px;
}
.panel-button.btn-default:hover {
    border-color: #838383;
}
.panel-button.btn-success {
    color: #292926;
    font-weight: bold;
    letter-spacing: 1px;
    border-color: #f4fd4f;
    background-color: #f4fd4f;
}
.panel-button.btn-success:hover {
    border-color: #eaae0e;
}
.panel-button.btn-success:active {
    color: #292926;
    background-color: #eaae0e;
}
.rotate {
    width: 12px;
    height: 12px;
    position: relative;
    float: right;
    margin-top: 4px;
    margin-left: 5px;
    display: inline-block;
    border-top: 2px solid #fff;
    border-right: 2px solid #fff;
}
.rotate-right {
    transform: rotate(45deg);
}
.rotate-left {
    margin-bottom: 4px;
    transform: rotate(-135deg);
}
.list-group-item{
    border: 0;
}
.list-group {
    margin:0;
}
#panel-list {
    margin-top: 40px;
}
.panel-list-item.list-group-item {
    border-bottom: 1px solid #716767;
    border-radius: 0;
    border-top: 1px solid #716767;
    background: #212121;
    padding: 18px 15px;
    cursor: pointer;
}
.panel-list-item.list-group-item:hover {
    background: #555;
}
.panel-list-item.list-group-item:active {
    background: #444;
}

/** Menu Iframe Panel **/

#frame-wrapper {
    position: fixed;
    top: 0;
    left: -350px;
    width: 80vw;
    max-width: 350px;
    height: 100%;
    transition: left 0.7s ease;
    z-index: 200;
    background-color: #292828;
}
#frame-wrapper.show {
    left: 0;
}
#frame-header {
    height: 40px;
}
.panel-iframe {
    height: 100%;
    width: 100%
}

.frame-button.btn-success {
    color: #fff;
    font-weight: bold;
    letter-spacing: 1px;
    border: 0;
    background-color: #292828;
}

.frame-button.btn-success:hover {
    border-color: #eaae0e;
    background-color: #333;
}

.frame-button.btn-success:active {
    border-color: #bbb;
    background-color: #555;
}

.button-left-container {
    padding-left: 0;
}

.button-right-container {
    padding-right: 0;
}

#frame-caption {
    text-align: center;
    height: 20px;
    padding-top: 10px;
}

#menu-iframe {
    width: 80vw;
    max-width: 350px;
    box-sizing: border-box;
    user-select: none;
    overflow: hidden;
    border: 0;
    background-color: #292926;
    background-size: 100% 100%;
    animation: iframeAnimation 1.5s ease-in-out infinite;
}

#frame-content {
    -webkit-overflow-scrolling: touch;
    overflow-x: hidden;
    overflow-y: auto;
    background-color: #292926;
    background-size: 100% 100%;
}

@keyframes iframeAnimation {
    0% { background-color: #292926; }
    50% { background-color: #353535; }
    100% { background-color: #292926; }
}

/** Popup **/

.popup-ctrl {
    height: 100%;
    width: 100%;
    z-index: 300;
    pointer-events: auto;
    position: absolute;
}

#popup-header {
    display: flex;
    height: 40px;
    overflow: hidden;
}

.popup-frame-button {
    width: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

#popup-overlay-area {
    position: absolute;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
}

#popup-container {
    position: relative;
    background-color: #292828;
    height: 90%;
    width: 90%;
    top: 5%;
    left: 5%;
    z-index: 100;
}

#popup-caption-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex: 1;
}

#popup-caption-text {
    font-size: 1.2em;
}

#popup-iframe-container {
    border: none;
    width: 100%;
    height: calc(100% - 40px); /* exclude #popup-header */
    /* iOS fix */
    overflow: auto;
    -webkit-overflow-scrolling: touch
}

#popup-iframe-element {
    width: 100%;
    height: 100%;
    border: none;
    animation: iframeAnimation 1.5s ease-in-out infinite;
}

.visible {
    visibility: visible !important;
}

/** Cross element **/

.cross {
    position: relative;
    width: 100%;
    margin: -2px 2px 0 0;
}

.cross:before, .cross:after {
    content: '';
    position: absolute;
    width: 50%;
    height: 3px;
    background-color: #fff;
    border-radius: 2px;
    top: 50%;
}

.cross:before {
    transform: rotate(45deg);
    left: 30%;
}

.cross:after {
    transform: rotate(-45deg);
    left: 30%;
}

.mobile-navigation-widget {
    position: absolute;
    pointer-events: auto;
    background-color: #212121;
    z-index: 50;
}

.game-overlay-widget {
    pointer-events: auto;
}

.tournaments-ingame-widget {
    pointer-events: auto;
}