:root {
    --path-color: #a0522d;
    --grass-color: #228b22;
    --player-color: #4682b4;
    --castle-color: #808080;
    --step-color: #d2b48c;
}

body {
    font-family: 'Georgia', serif;
    background: linear-gradient(to bottom, #87ceeb, #f0f8ff);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
}

.game-container {
    background: var(--grass-color);
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><text y="50" x="5" font-size="80">🌳</text><text y="95" x="60" font-size="60">🌲</text></svg>');
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 800px;
    padding: 30px;
    text-align: center;
    border: 10px solid #8b4513;
}

/* --- Telas --- */
.hidden { display: none; }

#start-screen h1, #end-screen h1 {
    font-size: 2.5em;
    color: #fff;
    text-shadow: 3px 3px 5px #000;
}

/* --- Seleção de Nível --- */
.level-selection {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}
.level-btn {
    padding: 15px;
    font-size: 1.2em;
    border-radius: 10px;
    border: 3px solid;
    color: white;
    cursor: pointer;
    transition: transform 0.2s;
}
.level-btn:hover { transform: scale(1.05); }
[data-level="easy"] { background-color: #28a745; border-color: #1e7e34; }
[data-level="medium"] { background-color: #ffc107; border-color: #d39e00; color: #333; }
[data-level="hard"] { background-color: #dc3545; border-color: #b02a37; }


/* --- Caminho e Personagem --- */
.progress-area { padding: 50px 0; }
.path {
    background-color: var(--path-color);
    height: 15px;
    border-radius: 10px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 0 20px;
    border: 2px solid #69381a;
}
.step {
    width: 20px;
    height: 20px;
    background-color: var(--step-color);
    border-radius: 50%;
    border: 2px solid #8b4513;
}
.castle {
    width: 60px;
    height: 60px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="90">🏰</text></svg>');
    background-size: contain;
    position: absolute;
    right: -25px;
    top: 50%;
    transform: translateY(-50%);
}
#player {
    width: 50px;
    height: 50px;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><text y=".9em" font-size="90">🧙</text></svg>');
    background-size: contain;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translate(-50%, -50%);
    transition: left 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Área do Quiz --- */
.quiz-area {
    background: rgba(245, 245, 220, 0.85);
    padding: 20px;
    border-radius: 15px;
    border: 2px solid #daa520;
}
#answer-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 20px 0;
}
.btn-answer {
    background-color: #fff8dc;
    border: 2px solid #daa520;
    border-radius: 10px;
    padding: 15px;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-answer:hover:not([disabled]) { transform: translateY(-3px); box-shadow: 0 4px 8px rgba(0,0,0,0.1); }
.btn-answer.correct { background-color: #98fb98; border-color: #2e8b57; }
.btn-answer.incorrect { background-color: #ffb6c1; border-color: #c71585; }
.btn-answer:disabled { cursor: not-allowed; opacity: 0.7; }

#feedback { font-size: 1.2em; font-weight: bold; height: 30px; }

#restart-btn {
    background-color: #6a5acd;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 15px 30px;
    font-size: 1.3em;
    cursor: pointer;
    transition: transform 0.2s;
}
#restart-btn:hover { transform: scale(1.1); }