body {
    font-family: 'Bangers', cursive;
    background-color: #A4D8C2;
    overflow: hidden;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    touch-action: none;
}

#game-container {
    position: relative;
    width: 100%;
    max-width: 1000px;
    height: 100vh;
    max-height: 600px;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.6);
}

canvas {
    display: block;
    background-color: #b8dccd;
    cursor: crosshair;
    touch-action: none;
}

.ui-element {
    position: absolute;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    font-size: 2.5rem;
    letter-spacing: 2px;
    user-select: none;
}

#power-bar-container {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 300px;
    height: 30px;
    background-color: rgba(0,0,0,0.3);
    border-radius: 15px;
    border: 3px solid white;
    overflow: hidden;
    z-index: 10;
}

#power-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #f0ad4e, #d9534f);
    border-radius: 12px;
    transition: width 0.1s linear;
}

.pause-icon, .sound-icon {
    cursor: pointer;
}

.hills {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 150px;
    background-image: url('https://www.transparenttextures.com/patterns/green-gobbler.png'),
                      radial-gradient(ellipse at bottom, #5cb85c 0%, #449d44 100%);
    background-repeat: repeat, no-repeat;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

.hill-1 {
    width: 120%;
    height: 150px;
    background: #6AAE55;
    border-radius: 50%;
    position: absolute;
    bottom: -50px;
    left: -10%;
    z-index: 1;
}

.hill-2 {
    width: 100%;
    height: 200px;
    background: #5A9A4D;
    border-radius: 50%;
    position: absolute;
    bottom: -100px;
    right: -15%;
    z-index: 0;
}

.menu {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 100;
}

.menu-box {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.menu-title {
    font-size: 3rem;
    color: #333;
    margin-bottom: 10px;
}

.menu-score {
     font-size: 2.5rem;
     color: #555;
}

.menu-button {
    padding: 15px 30px;
    border: none;
    border-radius: 50px;
    font-size: 1.8rem;
    cursor: pointer;
    transition: transform 0.2s;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.menu-button:hover {
    transform: scale(1.05);
}

.start-button {
    background-color: #5cb85c;
}

.exit-button {
    background-color: #d9534f;
}

.resume-button {
     background-color: #337ab7;
}

.hidden {
    display: none;
}

.mobile-hint {
    position: absolute;
    bottom: 60px;
    left: 0;
    width: 100%;
    text-align: center;
    color: white;
    font-size: 1.2rem;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    z-index: 20;
    display: none;
}

@media (max-width: 768px) {
    #game-container {
        max-height: 100vh;
        border-radius: 0;
    }

   .hill-1 {
    width: 150%;
    height: 80px;
    bottom: -10px;
    left: -25%;
    background: #6AAE55;
    border-top-left-radius: 75% 80px;
    border-top-right-radius: 75% 80px;
}

.hill-2 {
    width: 120%;
    height: 100px;
    bottom: -10px;
    right: -20%;
    background: #5A9A4D;
    border-top-left-radius: 70% 100px;
    border-top-right-radius: 70% 100px;
}

    
    .ui-element {
        font-size: 1.8rem;
    }
    
    #timer {
        font-size: 2.5rem !important;
        right: 10px !important;
    }
    
    #mute-button {
        top: 70px !important;
        right: 60px !important;
    }
    
    #pause-button {
        top: 70px !important;
        right: 10px !important;
    }
    
    .menu-title {
        font-size: 2.5rem;
    }
    
    .menu-button {
        padding: 10px 20px;
        font-size: 1.5rem;
    }
    
    #power-bar-container {
        width: 200px;
        height: 20px;
        bottom: 100px;
    }
    
    .mobile-hint {
        display: block;
    }
}

@media (max-width: 480px) {
    .ui-element {
        font-size: 1.5rem;
    }

    .hill-1 {
    width: 150%;
    height: 80px;
    bottom: -10px;
    left: -25%;
    background: #6AAE55;
    border-top-left-radius: 75% 80px;
    border-top-right-radius: 75% 80px;
}

.hill-2 {
    width: 120%;
    height: 100px;
    bottom: -10px;
    right: -20%;
    background: #5A9A4D;
    border-top-left-radius: 70% 100px;
    border-top-right-radius: 70% 100px;
}

    
    #timer {
        font-size: 2rem !important;
    }
    
    .menu-title {
        font-size: 2rem;
    }
    
    .menu-button {
        padding: 8px 16px;
        font-size: 1.2rem;
    }
    
    #power-bar-container {
        width: 150px;
    }
    
    #score, #shots {
        left: 10px !important;
    }
}


@media (max-width: 932px) and (max-height: 430px) {
    #game-container {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .hill-1 {
    width: 150%;
    height: 80px;
    bottom: -10px;
    left: -25%;
    background: #6AAE55;
    border-top-left-radius: 75% 80px;
    border-top-right-radius: 75% 80px;
}

.hill-2 {
    width: 120%;
    height: 100px;
    bottom: -10px;
    right: -20%;
    background: #5A9A4D;
    border-top-left-radius: 70% 100px;
    border-top-right-radius: 70% 100px;
}

    
    .ui-element {
        font-size: 1.5rem;
    }
    
    #timer {
        font-size: 1.8rem !important;
        right: 10px !important;
    }
    
    #mute-button, #pause-button {
        width: 25px;
        height: 25px;
        top: 10px !important;
    }
    
    #mute-button {
        right: 50px !important;
    }
    
    #pause-button {
        right: 15px !important;
    }
    
    #power-bar-container {
        width: 180px;
        height: 15px;
        bottom: 80px;
    }
    
    .menu-title {
        font-size: 2rem;
    }
    
    .menu-button {
        padding: 8px 16px;
        font-size: 1.2rem;
    }
    
    .mobile-hint {
        font-size: 1rem;
        bottom: 50px;
    }
}
