:root {
    --bg-sky: #70c5ce;
    --text-color: #ffffff;
    --shadow-color: #000000;
    --btn-bg: #e0ac2e;
    --btn-border: #f4ce62;
    --btn-border-dark: #583e0c;
    --font-retro: 'Press Start 2P', cursive;
}

* {
    box-sizing: border-box;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #333;
    font-family: var(--font-retro);
    display: flex;
    justify-content: center;
    align-items: center;
}

#game-container {
    position: relative;
    width: 100%;
    height: 100%;
    max-width: 480px; /* Mobile width usually */
    background-color: var(--bg-sky);
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

#game-canvas {
    display: block;
    width: 100%;
    height: 100%;
}

#ui-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.screen {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: rgba(0,0,0,0.4);
    pointer-events: auto;
    z-index: 10;
}

.hidden {
    display: none !important;
}

.title {
    font-size: 40px;
    color: var(--btn-bg);
    text-shadow: 4px 4px var(--shadow-color);
    margin-bottom: 40px;
    text-align: center;
    line-height: 1.2;
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.retro-btn {
    font-family: var(--font-retro);
    font-size: 16px;
    padding: 15px 30px;
    background: var(--btn-bg);
    color: var(--text-color);
    border: 4px solid var(--text-color);
    border-radius: 8px;
    box-shadow: 0 6px 0 var(--btn-border-dark);
    cursor: pointer;
    transition: transform 0.1s, box-shadow 0.1s;
    text-transform: uppercase;
}

.retro-btn:active {
    transform: translateY(6px);
    box-shadow: 0 0 0 var(--btn-border-dark);
}

.instructions {
    margin-top: 30px;
    color: white;
    text-shadow: 2px 2px black;
    font-size: 12px;
    text-align: center;
}

.score-board {
    background: #ded895;
    border: 4px solid #543847;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    width: 80%;
    display: flex;
    justify-content: space-around;
}

.score-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #e86101;
}

.score-item span:first-child {
    font-size: 12px;
    margin-bottom: 10px;
    color: #e86101;
}

.score-item span:last-child {
    font-size: 24px;
    color: #000;
}

#hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    pointer-events: none; /* Let clicks pass through to game/canvas */
    z-index: 5;
}

.score-display {
    font-size: 40px;
    color: white;
    text-shadow: 3px 3px black;
}

.ai-stats {
    font-size: 10px;
    color: white;
    text-shadow: 1px 1px black;
    text-align: right;
    background: rgba(0,0,0,0.5);
    padding: 5px;
    border-radius: 4px;
}

.icon-btn {
    pointer-events: auto;
    background: none;
    border: none;
    font-size: 24px;
    color: white;
    cursor: pointer;
    text-shadow: 2px 2px black;
}
