html,
body {
    width: 100%;
    height: 100dvh;
    margin: 0;
    padding: 0;

    overflow: hidden;
    background: #111;
}

body {
    display: flex;
    align-items: center;
    justify-content: center;
}

#unity-container,
#unity-container.unity-desktop,
#unity-container.unity-mobile {
    position: fixed;
    width: 390px;
    height: 844px;
    left: 50%;
    top: 50%;

    transform: translate(-50%, -50%);
    transform-origin: center center;
    overflow: hidden;
    background: #000;
    will-change: transform;
}

#unity-canvas,
#unity-canvas.unity-mobile,
.unity-mobile #unity-canvas {
    width: 390px !important;
    height: 844px !important;

    display: block;
    background: #000;
}

#unity-loading-bar {
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(88%, 340px);
    transform: translate(-50%, -50%);
    color: #fff;
    font-family: Arial, sans-serif;
    text-align: center;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.75);
}

#unity-loading-exit {
    position: absolute;
    top: 0;
    right: 0;
    /* Match Journey Page's 150 x 150 RectTransform on its 1080px-wide Canvas. */
    width: 13.8888889%;
    height: auto;
    aspect-ratio: 1 / 1;
    box-sizing: border-box;
    appearance: none;
    -webkit-appearance: none;
    padding: 0;
    border: 0;
    background: transparent url('exitButton_normal.png') center / 100% 100% no-repeat;
    cursor: pointer;
    z-index: 20;
}

#unity-loading-exit:active {
    background-image: url('exitButton_pressed.png');
}
#unity-progress-status {
    width: 150px;
    margin: 0 auto 10px;
    font-size: 18px;
    font-weight: 700;
    text-align: left;
    white-space: nowrap;
}

#unity-progress-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

#unity-progress-percent {
    min-width: 42px;
    font-size: 14px;
    font-weight: 700;
    text-align: right;
}

#unity-progress-details {
    min-height: 32px;
    margin-top: 10px;
    font-size: 12px;
    line-height: 16px;
}

#unity-logo { 
    width: 154px; 
    height: 130px; 
    background: url('unity-logo-dark.png') no-repeat center 
}

#unity-progress-bar-empty { 
    width: 141px; 
    height: 18px; 
    margin-top: 0; 
    margin-left: 0; 
    background: url('progress-bar-empty-dark.png') no-repeat center 
}

#unity-progress-bar-full { 
    width: 0%; 
    height: 18px; 
    margin-top: 0; 
    background: url('progress-bar-full-dark.png') no-repeat center 
}

#unity-footer {
    display:none;
}

.unity-mobile #unity-footer { 
    display: none 
}

#unity-build-title { 
    float: right; 
    margin-right: 10px; 
    line-height: 38px; 
    font-family: arial; 
    font-size: 18px 
}

#unity-fullscreen-button { 
    cursor:pointer; 
    float: right; 
    width: 38px; 
    height: 38px; 
    background: url('fullscreen-button.png') no-repeat center 
}

#unity-warning {
    left:5%;
    right:5%;
    width:auto;
}

@media (hover:hover) and (pointer:fine)
{
    #unity-container
    {
        border-radius:28px;
        box-shadow:0 0 40px rgba(0,0,0,.75);
    }
}

/* Mobile full-width presentation */
@media (max-width: 768px) {
    html,
    body {
        width: 100%;
        height: 100%;
        margin: 0;
        padding: 0;

        overflow: hidden;
        background: #000;
    }

    #unity-container,
    #unity-container.unity-desktop,
    #unity-container.unity-mobile {
        position: fixed;
        left: var(--unity-visible-left, 0px);
        top: var(--unity-visible-top, 0px);
        width: var(--unity-visible-width, 100vw);
        height: var(--unity-visible-height, 100dvh);

        transform: none;
        transform-origin: top left;
        border: none;
        border-radius: 0;
        box-shadow: none;

        box-sizing: border-box;
        padding-top: env(safe-area-inset-top, 0px);
        padding-right: env(safe-area-inset-right, 0px);
        padding-bottom: env(safe-area-inset-bottom, 0px);
        padding-left: env(safe-area-inset-left, 0px);

        overflow: hidden;
    }

    #unity-canvas,
    #unity-canvas.unity-mobile,
    .unity-mobile #unity-canvas {
        width: 100% !important;
        height: 100% !important;
        display: block;
    }
}
