html, body
{   
	width:  100%;
	height: 100%;
	margin: auto;
    padding: 0;
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
	overflow: hidden;
    z-index: -1000;
    background: #000;
    -webkit-tap-highlight-color: rgba(255, 255, 255, 0);
    -ms-touch-action: none;
	background-color: #0b1220;
}

.game-root {
    box-sizing: border-box;
    width: 100%;
    max-width: 100vw;
    height: 100%;
    max-height: 100vh;
    margin: 0 auto;
    position: relative;
    border: 0;
    padding: 0;
    padding-bottom: env(safe-area-inset-bottom, 0);
}

#wade_main_div
{
    margin: auto;
    position: absolute;
    padding: 0;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    border: none;
    outline: none;
    -webkit-backface-visibility: hidden;
    -webkit-perspective: 1000;
    -moz-user-select: none;
    -khtml-user-select: none;
    -webkit-user-select: none;
    user-select: none;
    -moz-transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
    -o-transform: translate3d(0, 0, 0);
    -ms-transform: translate3d(0, 0, 0);
	background-color:#000000;
}

canvas
{
    margin: auto;
    position: absolute;
    padding: 0;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    border: none;
    outline: none;
    -webkit-backface-visibility: hidden;
    -webkit-perspective: 1000;
    -moz-user-select: none;
    -khtml-user-select: none;
    -webkit-user-select: none;
    user-select: none;
    -moz-transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
    -o-transform: translate3d(0, 0, 0);
    -ms-transform: translate3d(0, 0, 0);
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    margin: 0 auto;
    box-sizing: border-box;
    background: linear-gradient(180deg, rgba(18, 28, 42, 0.92) 0%, rgba(8, 12, 20, 0.98) 100%);
    color: #e8eef5;
    text-align: center;
    padding: 12px 12px calc(12px + env(safe-area-inset-bottom, 0));
    z-index: 9998;
    pointer-events: none;
    border-top: 1px solid rgba(63, 183, 227, 0.35);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

#footerInstallRow {
    pointer-events: all;
    max-width: 44rem;
    margin: 0 auto;
    padding: 0 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.footer-install-actions {
    display: none;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px 14px;
}

#footerInstallButton {
    display: none;
    touch-action: manipulation;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    min-width: 44px;
    padding: 10px 20px;
    background: linear-gradient(180deg, #2a9fd6 0%, #1a7aad 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
    transition: transform 0.12s ease, filter 0.12s ease;
}

#footerInstallButton:hover {
    filter: brightness(1.08);
}

#footerInstallButton:active {
    transform: scale(0.98);
}

#footerNotNowInstall {
    display: none;
    touch-action: manipulation;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    min-width: 44px;
    padding: 10px 18px;
    background: transparent;
    color: #9db4c8;
    border: 1px solid rgba(157, 180, 200, 0.45);
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    transition: color 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}

#footerNotNowInstall:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.06);
}

#footerInstallButton:focus-visible,
#footerNotNowInstall:focus-visible,
#footerDismissInstallHint:focus-visible {
    outline: 2px solid #3fb7e3;
    outline-offset: 2px;
}

.footer-install-hint {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    text-align: center;
    color: #dce6ef;
    max-width: 36rem;
}

#footerDismissInstallHint {
    display: none;
    touch-action: manipulation;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 8px 18px;
    background: transparent;
    color: #9db4c8;
    border: 1px solid rgba(157, 180, 200, 0.35);
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
}

#footerDismissInstallHint:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.05);
}

/* Loading Screen Styles */
#loadingScreen {
    position: fixed;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8); /* Ensure spinner is visible with a semi-transparent background */
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999; /* Ensure it stays on top of all content */
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top-color: #148cb8;
    border-radius: 50%;
    animation: spin 1s ease infinite;
}

#progressText {
    margin-top: 10px;
    color: #fff;
    font-family: Arial, sans-serif;
    z-index: 10000;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loadingImage_class
{
    margin: 0 auto;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
}

/* Font face definitions */
@font-face {
    font-family: 'ArtDept1';
    src: url('fonts/Akashi.eot');
    src: url('fonts/Akashi.eot?#iefix') format('embedded-opentype'),
    url('fonts/Akashi.woff') format('woff'),
    url('fonts/Akashi.ttf') format('truetype'),
    url('fonts/Akashi.svg#freckleface') format('svg');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Monopower';
    src: url('fonts/MonospaceTypewriter.eot');
    src: url('fonts/MonospaceTypewriter.eot?#iefix') format('embedded-opentype'),
    url('fonts/MonospaceTypewriter.woff') format('woff'),
    url('fonts/MonospaceTypewriter.ttf') format('truetype'),
    url('fonts/MonospaceTypewriter.svg#freckleface') format('svg');
    font-weight: normal;
    font-style: normal;
}

#chromeFix {
    font: 16px ArtDept1;
}

#chromeFix2 {
    font: 16px Monopower;
}

/* Media query to handle smaller screens */
@media screen and (max-width: 768px) {
    #wade_main_div {
        max-width: 100%;
        height: auto;
        padding: 10px;
    }

    .footer-install-hint {
        font-size: 13px;
    }
}

@media (prefers-reduced-motion: reduce) {
    #footerInstallButton,
    #footerNotNowInstall {
        transition: none;
    }

    .spinner {
        animation: none;
        border-top-color: rgba(255, 255, 255, 0.5);
    }
}

