/* Reset en basis styling */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #87CEEB 0%, #98FB98 100%);
    margin: 0;
    padding: 0;
    height: 100vh;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
}

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

#gameCanvas {
    background: linear-gradient(to bottom, #87CEEB 0%, #98FB98 70%, #228B22 100%);
    border: 2px solid #4CAF50;
    border-radius: 10px;
    max-width: 100%;
    max-height: 100%;
    touch-action: none;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.screen {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.95);
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.screen h1 {
    font-size: 2.5em;
    color: #2E7D32;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.screen h2 {
    font-size: 2em;
    color: #D32F2F;
    margin-bottom: 20px;
}

.screen p {
    font-size: 1.2em;
    margin: 10px 0;
    color: #333;
}

button {
    background: linear-gradient(45deg, #4CAF50, #45a049);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1.3em;
    border-radius: 50px;
    cursor: pointer;
    margin: 10px;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.4);
    transition: all 0.3s ease;
    min-width: 150px;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.6);
}

button:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(76, 175, 80, 0.4);
}

.hidden {
    display: none !important;
}

.game-ui {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100;
    color: white;
    font-size: 1.5em;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
    background: rgba(0,0,0,0.3);
    padding: 10px 15px;
    border-radius: 15px;
    backdrop-filter: blur(5px);
}

.score, .bananas {
    margin: 5px 0;
}

.high-score {
    margin-top: 20px;
    font-size: 1.1em;
    color: #666;
    padding: 10px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: 10px;
}

/* Mobiele optimalisaties */
@media (max-width: 768px) {
    .screen {
        width: 90%;
        max-width: 400px;
        padding: 25px 20px;
    }
    
    .screen h1 {
        font-size: 2em;
    }
    
    .screen p {
        font-size: 1.1em;
    }
    
    button {
        font-size: 1.2em;
        padding: 12px 25px;
        min-width: 130px;
    }
    
    .game-ui {
        font-size: 1.3em;
        top: 15px;
        left: 15px;
        padding: 8px 12px;
    }
}

@media (max-width: 480px) {
    .screen h1 {
        font-size: 1.8em;
    }
    
    .screen p {
        font-size: 1em;
    }
    
    button {
        font-size: 1.1em;
        padding: 10px 20px;
        min-width: 120px;
    }
    
    .game-ui {
        font-size: 1.2em;
        top: 10px;
        left: 10px;
        padding: 6px 10px;
    }
}

/* Animaties */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.screen {
    animation: bounce 0.5s ease-in;
}

/* PWA styling voor volledig scherm */
@media (display-mode: standalone) {
    body {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* Landscape mode op mobiel */
@media screen and (orientation: landscape) and (max-height: 500px) {
    .screen {
        padding: 20px 15px;
        max-height: 90vh;
        overflow-y: auto;
    }
    
    .screen h1 {
        font-size: 1.6em;
        margin-bottom: 15px;
    }
    
    .screen p {
        font-size: 0.9em;
        margin: 8px 0;
    }
    
    button {
        font-size: 1em;
        padding: 8px 16px;
        min-width: 100px;
    }
}