body {
    margin: 0;
    overflow: hidden;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #87CEEB; /* Sky Blue */
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

#ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: 10;
}

/* Top Bar */
#top-bar {
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    gap: 10px;
}

.mode-badge {
    background: rgba(0,0,0,0.4);
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    cursor: pointer;
    border: 1px solid rgba(255,255,255,0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background 0.2s;
}
.mode-badge:active { background: rgba(0,0,0,0.6); }

#pokemon-name {
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    padding: 10px 25px;
    border-radius: 30px;
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    text-shadow: 0 1px 0 rgba(255,255,255,1);
    border: 3px solid #333;
    transform: translateY(-80px);
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
#pokemon-name.visible {
    transform: translateY(0);
}

#loading {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 20px 40px;
    border-radius: 15px;
    font-size: 1.2rem;
    pointer-events: auto;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: opacity 0.3s;
}

#message {
    margin-top: 25%;
    text-align: center;
    font-size: 4rem;
    font-weight: 900;
    color: #ffcb05; 
    -webkit-text-stroke: 2px #2a75bb; 
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    transform: scale(0.5);
    text-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

#controls {
    position: absolute;
    bottom: 40px;
    width: 100%;
    display: flex;
    justify-content: center;
    pointer-events: auto;
    gap: 20px;
}

/* Throw Button */
#btn-throw {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ff4d4d, #cc0000);
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    font-size: 1.1rem;
    text-transform: uppercase;
    outline: none;
    transition: transform 0.1s;
}

#btn-throw:active { transform: scale(0.9); background: #a00; }

/* Menu Buttons */
#post-catch-controls {
    display: none;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.btn-action {
    background: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.1rem;
    border-radius: 30px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    color: #333;
    min-width: 200px;
    text-transform: uppercase;
}
.btn-next { background: #4CAF50; color: white; border: 2px solid #2E7D32; }
.btn-release { background: #ff4d4d; color: white; border: 2px solid #b71c1c; }

#instructions {
    position: absolute;
    top: 130px;
    width: 100%;
    text-align: center;
    color: white;
    font-size: 1rem;
    opacity: 0.8;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}
