@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700;900&display=swap');

body {
    font-family: 'Poppins', sans-serif;
}

.game-wrapper {
    width: 100%;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

#gameCanvas {
    aspect-ratio: 16/9;
    height: 100%;
    width: auto;
    max-width: 100%;
    border: 8px solid #2d3748;
    border-radius: 12px;
    background: #87CEEB;
    touch-action: none;
    image-rendering: pixelated;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.85);
    color: white;
    z-index: 20;
    border-radius: 6px;
    transition: opacity 0.3s;
}

.hidden {
    display: none !important;
}

.char-card {
    transition: all 0.2s;
    border: 4px solid transparent;
}

.char-card:hover {
    transform: scale(1.05);
    border-color: #f59e0b;
}

.char-card.selected {
    background-color: #fffbeb;
    border-color: #d97706;
    box-shadow: 0 0 25px rgba(245, 158, 11, 0.6);
    transform: scale(1.05);
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.float-anim {
    animation: float 3s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% { text-shadow: 0 0 20px rgba(245, 158, 11, 0.5); }
    50% { text-shadow: 0 0 40px rgba(245, 158, 11, 0.8), 0 0 60px rgba(245, 158, 11, 0.3); }
}

.pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

.ability-indicator {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    pointer-events: none;
    z-index: 25;
}

.ability-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    position: relative;
    border: 3px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(8px);
}

.ability-icon .cooldown-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.7);
    transition: height 0.1s;
    border-radius: 0 0 7px 7px;
}

.ability-icon .key-hint {
    position: absolute;
    bottom: -16px;
    font-size: 10px;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
}

@keyframes shake {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(-4px, 2px); }
    50% { transform: translate(4px, -2px); }
    75% { transform: translate(-2px, 4px); }
}

.screen-shake {
    animation: shake 0.15s ease-in-out;
}
