/**
 * Copyright (c) 2026 Tenaya AI, Inc. All rights reserved.
 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #1a1a2e;
    font-family: monospace;
}

#game-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

#game-canvas {
    image-rendering: pixelated;
    image-rendering: crisp-edges;
    background-color: #87CEEB;
    max-width: 100%;
    max-height: 100%;
}

/* Touch Controls */
#touch-controls {
    display: none;
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    padding: 0 20px;
    pointer-events: none;
}

.touch-btn {
    position: absolute;
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    transition: background 0.1s;
}

.touch-btn:active {
    background: rgba(255, 255, 255, 0.4);
}

.touch-btn span {
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    font-weight: bold;
}

#touch-left {
    left: 20px;
    bottom: 0;
}

#touch-right {
    left: 110px;
    bottom: 0;
}

#touch-jump {
    right: 20px;
    bottom: 0;
    width: 90px;
}

/* Show touch controls on touch devices */
@media (hover: none) and (pointer: coarse) {
    #touch-controls {
        display: block;
    }
}

/* Landscape orientation adjustments */
@media (max-height: 500px) and (orientation: landscape) {
    #touch-controls {
        bottom: 10px;
    }

    .touch-btn {
        width: 60px;
        height: 60px;
    }

    #touch-jump {
        width: 80px;
    }
}
