body {
    overflow-x: hidden;
    overflow-y: hidden;
    font-family: 'VT323', monospace;
    font-size: 20px;
    background: #6B88FF;
    margin: 0;
    padding: 0;
    height: 100vh;
    width: 100vw;
    position: fixed; /* Prevent bouncing on iOS */
}

b, span {
    display: block;
}

b {
    margin-bottom: 15px;
    font-size: 30px;
}

#floor {
    position: absolute;
    background: url('img/floor.png');
    bottom: 0;
    width: 100%;
    left: 0;
    height: 106px;
    z-index: 50;
}

#scroll {
    position: absolute;
    top: 0;
    bottom: 106px;
    display: flex;
    white-space: nowrap;
    background: url('img/background.png') no-repeat;
    background-size: cover;
    align-items: center;
    min-height: calc(100vh - 106px);
}

#mario {
    background-image: url('img/mario.png?v=2');
    background-position: top left;
    background-repeat: no-repeat;
    position: fixed;
    z-index: 100;
    bottom: 106px;
    left: 50%;
    margin-left: -30px;
    width: 65px;
    height: 129px;
    background-blend-mode: color;
}

.box {
    position: relative;
    height: 270px;
    display: inline-block;
    background: white;
    padding: 20px;
    margin-left: 100px;
    margin-right: 0;
    width: 300px;
    flex-shrink: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    box-sizing: border-box;
    z-index: 10;
    overflow-y: auto; /* Allow scrolling within box if content overflows */
}

/* Mobile-specific styles */
@media (max-width: 768px) {
    body {
        font-size: 18px;
        position: fixed;
        width: 100%;
        height: 100%;
        overflow: hidden;
    }
    
    b {
        font-size: 26px;
    }
    
    #scroll {
        position: fixed;
        top: 0;
        height: calc(100% - 106px);
        padding-bottom: 0;
        align-items: center;
        justify-content: flex-start;
        overflow: hidden;
    }
    
    .box {
        margin-left: 60px;
        width: 280px;
        height: 270px;
        position: relative;
    }
    
    #floor {
        position: fixed;
        bottom: 0;
        height: 106px;
        width: 100%;
        left: 0;
        z-index: 50;
    }
    
    #mario {
        position: fixed;
        bottom: 106px;
        left: 50%;
        margin-left: -30px;
        z-index: 100;
    }
    
    #btn_left, #btn_right {
        background-color: rgba(0, 0, 0, 0.2);
        border-radius: 50%;
        width: 80px;
        height: 80px;
        display: flex;
        align-items: center;
        justify-content: center;
        bottom: 20px;
        position: fixed;
        z-index: 200;
    }
}

#btn_left {
    font-size: 80px;
    color: white;
    position: fixed;
    left: 20px;
    bottom: 10px;
    cursor: pointer;
    z-index: 200;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

#btn_right {
    font-size: 80px;
    color: white;
    position: fixed;
    right: 20px;
    bottom: 10px;
    cursor: pointer;
    z-index: 200;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}