* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    touch-action: none;
}

body {
    background-color: #1a252c;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    overflow: hidden;
    color: #fff;
}

#ui-container {
    display: flex;
    justify-content: space-between;
    width: 100%;
    max-width: 400px;
    padding: 15px 20px;
    font-size: 1.2rem;
    font-weight: 800;
    background: #2c3e50;
    border-radius: 12px 12px 0 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    z-index: 10;
}

#score-display {
    color: #f1c40f;
}

#highscore-display {
    color: #2ecc71;
}

#game-container {
    position: relative;
    width: 100%;
    max-width: 400px;
    aspect-ratio: 2 / 3;
    max-height: 80vh;
    background: linear-gradient(to bottom, #87CEEB 0%, #E0F6FF 100%);
    border-radius: 0 0 12px 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    overflow: hidden;
}

canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 37, 44, 0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    transition: opacity 0.3s ease;
    z-index: 20;
}

.overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.overlay h1 {
    font-size: 2.8rem;
    color: #e74c3c;
    margin-bottom: 15px;
    text-transform: uppercase;
    text-shadow: 3px 3px 0px #c0392b;
    letter-spacing: 2px;
}

#start-overlay h1 {
    color: #f1c40f;
    text-shadow: 3px 3px 0px #f39c12;
}

.overlay p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-weight: 600;
    color: #ecf0f1;
}
