/* chuva-alfabetica-v2 - game.css */
:root { --primary: #5e4fa2; --secondary: #e91e63; }

#gameWrapper {
    background: linear-gradient(135deg, #fff9f0 0%, #f3eeff 50%, #e8f4ff 100%);
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(94,79,162,0.15);
    padding: 20px;
    position: relative;
    min-height: 480px;
    margin-bottom: 24px;
    overflow: hidden;
}

.btn-fullscreen {
    position: absolute; top: 12px; right: 12px;
    background: transparent; border: 2px solid var(--primary);
    color: var(--primary); border-radius: 8px;
    width: 36px; height: 36px; cursor: pointer; font-size: 18px;
    z-index: 10; transition: transform .2s;
}
.btn-fullscreen:hover { transform: scale(1.15); }

#gameWrapper:fullscreen,
#gameWrapper:-webkit-full-screen,
#gameWrapper:-moz-full-screen,
#gameWrapper:-ms-fullscreen {
    width: 100%; height: 100vh;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    border-radius: 0;
}

/* Seleção de modo */
#modeSelect { text-align: center; padding: 30px 10px; }
.mode-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.mode-btn {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff; border: none; border-radius: 16px;
    padding: 18px 28px; font-size: 18px; cursor: pointer;
    font-weight: bold; transition: transform .2s, box-shadow .2s;
    box-shadow: 0 4px 12px rgba(94,79,162,0.3);
    min-width: 140px;
}
.mode-btn:hover { transform: scale(1.07); box-shadow: 0 8px 20px rgba(94,79,162,0.4); }
.mode-btn small { display: block; font-size: 13px; opacity: 0.85; margin-top: 4px; }

/* Barra de info */
.game-info-bar {
    display: flex; gap: 16px; align-items: center; justify-content: center;
    background: rgba(94,79,162,0.08); border-radius: 12px;
    padding: 10px 16px; margin-bottom: 12px; flex-wrap: wrap;
    font-size: 15px; color: #333; font-weight: 600;
}
.game-info-bar strong { color: var(--primary); font-size: 20px; }

/* Área de chuva */
#rainArea {
    position: relative; width: 100%; height: 380px;
    background: linear-gradient(180deg, #e8f4ff 0%, #f3eeff 100%);
    border-radius: 16px; overflow: hidden;
}

.letter-drop {
    position: absolute;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff; font-size: 28px; font-weight: bold;
    width: 56px; height: 56px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; user-select: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    transition: top linear;
}
.letter-drop:hover { transform: scale(1.1); }
.letter-drop.pop {
    animation: popBig 0.4s ease forwards;
}
.letter-drop.shake {
    animation: shake 0.5s ease;
}

/* Tela de vitória */
#victoryScreen {
    display: none; position: absolute; inset: 0;
    background: linear-gradient(135deg, #f3eeff, #fff9f0);
    border-radius: 24px; flex-direction: column;
    align-items: center; justify-content: center; z-index: 20;
}
.victory-content { text-align: center; z-index: 1; }
.victory-trophy { font-size: 72px; animation: trophyBounce 1s ease infinite alternate; }
#starsRow { font-size: 42px; animation: starsIn 0.8s ease; }
.btn-play-again {
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    color: #fff; border: none; border-radius: 50px;
    padding: 14px 32px; font-size: 18px; font-weight: bold;
    cursor: pointer; margin-top: 16px;
    transition: transform .2s;
}
.btn-play-again:hover { transform: scale(1.05); }

#confettiContainer { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.confetti-piece {
    position: absolute; width: 10px; height: 10px;
    border-radius: 2px; animation: confettiFall linear forwards;
}

/* Animações */
@keyframes shake {
    0%,100% { transform: translateX(0); }
    25% { transform: translateX(-8px); }
    75% { transform: translateX(8px); }
}
@keyframes popBig {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.5); opacity: 0.7; }
    100% { transform: scale(0); opacity: 0; }
}
@keyframes trophyBounce {
    from { transform: translateY(0); }
    to { transform: translateY(-16px); }
}
@keyframes starsIn {
    from { opacity: 0; transform: scale(0.5); }
    to { opacity: 1; transform: scale(1); }
}
@keyframes confettiFall {
    from { transform: translateY(-20px) rotate(0deg); opacity: 1; }
    to { transform: translateY(500px) rotate(360deg); opacity: 0; }
}

/* Responsivo */
@media (max-width: 480px) {
    .letter-drop { width: 48px; height: 48px; font-size: 22px; }
    .mode-btn { padding: 14px 18px; font-size: 15px; }
    #rainArea { height: 300px; }
}
