/* Mobile-first responsive styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #F5F5F5;

    /* Prevent pull-to-refresh and overscroll */
    overscroll-behavior: none;
    -webkit-overflow-scrolling: none;

    /* Prevent text selection */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;

    /* Prevent tap highlight */
    -webkit-tap-highlight-color: transparent;
}

#game-canvas {
    display: block;
    width: 100%;
    height: 100%;

    /* Disable all touch actions - we handle them in JS */
    touch-action: none;

    /* Prevent context menu on long press */
    -webkit-touch-callout: none;
}

/* Safe area handling for notched devices */
@supports (padding: env(safe-area-inset-top)) {
    body {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }
}

/* Prevent iOS rubber-banding */
body {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}
