* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    background: transparent;
    font-family: 'Press Start 2P', cursive;
}

#bgCanvas {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 0;
}

#gameCanvas {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1;
    background: transparent;
}

.ui-overlay {
    position: fixed;
    z-index: 2;
    pointer-events: none;
}

.top-bar {
    top: 0;
    left: 0;
    right: 0;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.4);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: auto;
    height: 50px;
}

.control-panel {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.btn {
    background: linear-gradient(180deg, rgba(68, 68, 68, 0.9) 0%, rgba(51, 51, 51, 0.9) 100%);
    color: #fff;
    border: 1.5px solid rgba(102, 102, 102, 0.7);
    padding: 8px 12px;
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.1s;
    box-shadow: 0 2px 0 rgba(34, 34, 34, 0.5);
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

@media (max-width: 768px) {
    .btn {
        padding: 10px 14px;
        font-size: 11px;
    }
    
    .top-bar {
        padding: 6px 8px;
        height: auto;
        min-height: 50px;
    }
    
    .control-panel {
        gap: 3px;
        justify-content: center;
    }
}

.btn:hover {
    background: linear-gradient(180deg, rgba(85, 85, 85, 0.9) 0%, rgba(68, 68, 68, 0.9) 100%);
    border-color: rgba(136, 136, 136, 0.8);
    transform: translateY(-0.5px);
}

.btn:active {
    transform: translateY(1px);
    box-shadow: 0 0.5px 0 rgba(34, 34, 34, 0.5);
}

.btn-a {
    background: linear-gradient(180deg, rgba(255, 107, 107, 0.9) 0%, rgba(204, 85, 85, 0.9) 100%);
    border-color: rgba(255, 136, 136, 0.8);
}

.btn-a:hover {
    background: linear-gradient(180deg, rgba(255, 122, 122, 0.9) 0%, rgba(221, 102, 102, 0.9) 100%);
    border-color: rgba(255, 153, 153, 0.9);
}

.btn-b {
    background: linear-gradient(180deg, rgba(107, 159, 255, 0.9) 0%, rgba(85, 119, 204, 0.9) 100%);
    border-color: rgba(136, 184, 255, 0.8);
}

.btn-b:hover {
    background: linear-gradient(180deg, rgba(122, 160, 255, 0.9) 0%, rgba(102, 136, 221, 0.9) 100%);
    border-color: rgba(153, 200, 255, 0.9);
}

.btn-fan {
    background: linear-gradient(180deg, rgba(170, 68, 255, 0.9) 0%, rgba(136, 34, 204, 0.9) 100%);
    border-color: rgba(204, 102, 255, 0.8);
}

.btn-fan:hover {
    background: linear-gradient(180deg, rgba(187, 85, 255, 0.9) 0%, rgba(153, 51, 221, 0.9) 100%);
    border-color: rgba(221, 136, 255, 0.9);
}

.btn-test {
    background: linear-gradient(180deg, rgba(255, 200, 0, 0.9) 0%, rgba(200, 150, 0, 0.9) 100%);
    border-color: rgba(255, 220, 50, 0.8);
}

.btn-test:hover {
    background: linear-gradient(180deg, rgba(255, 220, 50, 0.9) 0%, rgba(220, 170, 20, 0.9) 100%);
    border-color: rgba(255, 240, 100, 0.9);
}

.btn-danmaku {
    background: linear-gradient(180deg, rgba(80, 200, 120, 0.9) 0%, rgba(60, 160, 90, 0.9) 100%);
    border-color: rgba(100, 220, 150, 0.8);
}

.btn-danmaku:hover {
    background: linear-gradient(180deg, rgba(100, 220, 140, 0.9) 0%, rgba(70, 180, 100, 0.9) 100%);
    border-color: rgba(120, 240, 170, 0.9);
}


