@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&display=swap');

body {
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #ff9a9e 0%, #fad0c4 99%, #fad0c4 100%);
    font-family: 'Fredoka One', cursive, sans-serif;
    user-select: none;
    overflow-x: hidden;
    color: #333;
}

.screen {
    display: none;
    width: 100vw;
    height: 100vh;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    padding: 20px;
}

.screen.active {
    display: flex;
}

/* TAMPILAN UTAMA / KARAKTER */
h1 {
    font-size: 3rem;
    color: #fff;
    text-shadow: 3px 3px 0px #ff6b6b, 6px 6px 0px rgba(0,0,0,0.2);
    text-align: center;
    margin-bottom: 20px;
}

.character-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.char-card {
    background: white;
    border-radius: 30px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
    transition: transform 0.2s, background 0.2s;
    border: 5px solid #ffd166;
}

.char-card:hover, .char-card.selected {
    transform: scale(1.1);
    background: #fff1c1;
    border-color: #ff4757;
}

.char-card img {
    width: 100px;
    height: 100px;
    object-fit: contain;
}

.btn-besar {
    background: #06d6a0;
    color: white;
    border: none;
    padding: 20px 50px;
    font-size: 2.2rem;
    font-family: 'Fredoka One', cursive;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 8px 0 #058c67, 0 15px 20px rgba(0,0,0,0.2);
    transition: all 0.1s ease;
}

.btn-besar:active {
    transform: translateY(6px);
    box-shadow: 0 2px 0 #058c67, 0 5px 10px rgba(0,0,0,0.2);
}

/* PETA LEVEL */
.map-header {
    display: flex;
    justify-content: space-between;
    width: 100%;
    max-width: 600px;
    margin-bottom: 20px;
    font-size: 1.5rem;
    color: white;
    text-shadow: 2px 2px 0 #333;
}

.level-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 15px;
    max-height: 65vh;
    overflow-y: auto;
    padding: 15px;
    background: rgba(255,255,255,0.4);
    border-radius: 25px;
    width: 100%;
    max-width: 600px;
}

.level-btn {
    background: #4cc9f0;
    color: white;
    border: none;
    border-radius: 20px;
    font-size: 1.6rem;
    font-family: 'Fredoka One', cursive;
    aspect-ratio: 1;
    cursor: pointer;
    box-shadow: 0 6px 0 #3a9bbd;
    transition: transform 0.1s;
}

.level-btn.locked {
    background: #adb5bd;
    box-shadow: 0 6px 0 #6c757d;
    cursor: not-allowed;
}

.level-btn:not(.locked):active {
    transform: scale(0.95);
}

/* GAMEPLAY ARENA */
.game-top-bar {
    display: flex;
    justify-content: space-between;
    width: 100%;
    max-width: 700px;
    align-items: center;
    margin-bottom: 10px;
}

.speaker-btn {
    background: #ffd166;
    border: none;
    border-radius: 50%;
    width: 70px;
    height: 70px;
    font-size: 2rem;
    cursor: pointer;
    box-shadow: 0 5px 0 #e0a82e;
    transition: transform 0.1s;
}

.speaker-btn:active {
    transform: scale(0.9);
}

.question-card {
    background: white;
    border-radius: 30px;
    padding: 25px;
    width: 100%;
    max-width: 700px;
    text-align: center;
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
    border: 6px solid #118ab2;
    margin-bottom: 20px;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.visual-container {
    font-size: 3rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin: 15px 0;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    width: 100%;
    max-width: 700px;
}

.option-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    border-radius: 25px;
    padding: 20px;
    font-size: 2.5rem;
    font-family: 'Fredoka One', cursive;
    cursor: pointer;
    box-shadow: 0 8px 0 #d93838, 0 10px 15px rgba(0,0,0,0.2);
    transition: transform 0.1s;
}

.option-btn:active {
    transform: translateY(5px);
    box-shadow: 0 3px 0 #d93838;
}

/* ANIMASI REAKSI KARAKTER */
.pet-avatar {
    position: fixed;
    bottom: 10px;
    left: 10px;
    width: 110px;
    height: 110px;
    background: white;
    border-radius: 50%;
    border: 4px solid #ffd166;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 10;
}

.pet-avatar img {
    width: 85px;
    height: 85px;
    object-fit: contain;
    transition: transform 0.3s;
}

.bounce {
    animation: bounceAnim 0.5s infinite alternate;
}

@keyframes bounceAnim {
    from { transform: translateY(0); }
    to { transform: translateY(-15px); }
}

/* MODAL HADIAH */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6);
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.modal-content {
    background: white;
    padding: 40px;
    border-radius: 35px;
    text-align: center;
    border: 8px solid #06d6a0;
    max-width: 400px;
    width: 90%;
    animation: popUp 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popUp {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}