:root {
    /* Cute Color Palette */
    --bg-color: #2b213a;          /* Deep Purple/Space */
    --canvas-bg: #1a1625;
    --accent-pink: #ff9fb2;       /* Pastel Pink */
    --accent-mint: #a8ffdb;       /* Mint Green */
    --accent-blue: #a3d9ff;       /* Soft Blue */
    --accent-yellow: #fff5ba;     /* Light Yellow */
    --text-color: #ffffff;
    --ui-overlay-bg: rgba(43, 33, 58, 0.9);
    
    --font-primary: 'Nunito', sans-serif;
    --font-display: 'Quicksand', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-primary);
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    /* Cute subtle gradient background */
    background: radial-gradient(circle at 50% 50%, #3d2f50 0%, #2b213a 100%);
}

#game-container {
    position: relative;
    width: 800px;
    height: 600px;
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
    border-radius: 20px;
    overflow: hidden;
}

#game-canvas {
    background-color: var(--canvas-bg);
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 20px;
}

/* UI Layer (HUD) */
#ui-layer {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    z-index: 10;
}

.label {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--accent-blue);
    margin-right: 10px;
    text-shadow: 0 0 10px rgba(163, 217, 255, 0.5);
}

#score-value {
    font-family: var(--font-primary);
    font-weight: 900;
    font-size: 1.5rem;
    color: var(--text-color);
}

#lives-container {
    display: inline-flex;
    gap: 5px;
}

.heart {
    font-size: 1.5rem;
    filter: drop-shadow(0 0 5px rgba(255, 159, 178, 0.6));
    animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Overlays (Start, Game Over) */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--ui-overlay-bg);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 20;
    backdrop-filter: blur(5px);
    transition: opacity 0.3s ease;
}

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

.overlay.active {
    opacity: 1;
    pointer-events: all;
}

.title {
    font-family: var(--font-display);
    font-size: 4rem;
    font-weight: 700;
    text-align: center;
    line-height: 1.1;
    margin-bottom: 10px;
    background: linear-gradient(to right, var(--accent-pink), var(--accent-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 20px rgba(255, 159, 178, 0.4));
}

.subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--accent-mint);
}

.instructions {
    margin-bottom: 3rem;
    opacity: 0.8;
}

/* Interactive Buttons */
.primary-btn {
    background: linear-gradient(45deg, var(--accent-pink), #ff7eb3);
    border: none;
    padding: 15px 40px;
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(255, 126, 179, 0.3);
    transition: transform 0.2s, box-shadow 0.2s;
}

.primary-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 30px rgba(255, 126, 179, 0.5);
}

.primary-btn:active {
    transform: translateY(1px) scale(0.98);
}
