:root {
    --fast-to-win-safe-top: env(safe-area-inset-top, 0px);
    --fast-to-win-safe-right: env(safe-area-inset-right, 0px);
    --fast-to-win-raw-safe-bottom: env(safe-area-inset-bottom, 0px);
    --fast-to-win-safe-bottom: min(var(--fast-to-win-raw-safe-bottom), 12px);
    --fast-to-win-safe-left: env(safe-area-inset-left, 0px);
    --fast-to-win-viewport-height: 100vh;
    color-scheme: dark;
    background: #06132f;
    background-color: #06132f;
}

html,
body {
    width: 100%;
    min-width: 320px;
    height: 100%;
    height: var(--fast-to-win-viewport-height);
    min-height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: #06132f;
    overscroll-behavior: none;
}

#fastToWinRoot {
    position: fixed;
    inset: 0 0 auto;
    height: var(--fast-to-win-viewport-height);
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    overscroll-behavior: none;
    background-color: #06132f;
}

#fastToWinSafeAreaProbe {
    position: fixed;
    inset: 0;
    box-sizing: border-box;
    padding:
        var(--fast-to-win-safe-top)
        var(--fast-to-win-safe-right)
        var(--fast-to-win-safe-bottom)
        var(--fast-to-win-safe-left);
    visibility: hidden;
    pointer-events: none;
}

#fastToWinStatusBarTint {
    display: none;
}

/* Experimental iOS 27 PWA workaround, not a CSS opt-out for system blur.
   The solid DOM strip gives WebKit an unambiguous status-bar tint even
   though the actual app header is rendered inside a canvas/shadow root. */
html[data-ios-status-bar-tint="true"] {
    --fast-to-win-status-tint-height: 16px;
    --fast-to-win-header-background: #071a44; /* ArcadePalette.Navy900 */
    --fast-to-win-safe-top: max(env(safe-area-inset-top, 0px), var(--fast-to-win-status-tint-height));
}

html[data-ios-status-bar-tint="true"] #fastToWinStatusBarTint {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--fast-to-win-status-tint-height);
    background-color: var(--fast-to-win-header-background);
    z-index: 1;
    pointer-events: none;
}

body {
    background: #071a3b;
    background-color: #071a3b;
    overscroll-behavior: none;
    -webkit-tap-highlight-color: transparent;
}

canvas {
    display: block;
    max-width: 100%;
    max-height: 100%;
    outline: none;
    touch-action: manipulation;
}

noscript {
    display: block;
    max-width: 36rem;
    margin: 4rem auto;
    padding: 1.5rem;
    color: #ffffff;
    font: 600 1rem/1.5 system-ui, sans-serif;
    text-align: center;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
    }
}
