body {
    font-family: 'Lilita One', cursive;
    background-color: #f0f8ff;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    color: #333;
    user-select: none;
}

#score-container {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: #fffacd;
    padding: 10px 15px;
    border-radius: 10px;
    border: 2px solid #ffd700;
    font-size: 1.2em;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
}

#score-container span {
    margin: 0 10px;
}

#hits-count {
    color: #32cd32;
    font-weight: bold;
}

#misses-count {
    color: #dc143c;
    font-weight: bold;
}

#game-container {
    position: relative;
    background-color: #ffffff;
    padding: 20px 40px;
    border-radius: 20px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    text-align: center;
    border: 5px solid #66c2ff;
    width: 90%;
    max-width: 800px;
}

h1 {
    color: #ff6347;
    font-size: 2.5em;
    margin-bottom: 20px;
    text-shadow: 2px 2px #fdfd96;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 0 0 20px 20px;
    z-index: 10;
}

#image-container {
    margin-bottom: 20px;
    height: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
}

#word-image {
    max-width: 100%;
    max-height: 220px;
    border-radius: 15px;
}

#answer-wrapper {
    position: relative;
    margin-bottom: 20px;
    min-height: 80px;
}

.syllable-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    min-height: 80px;
    padding: 10px;
    border-radius: 10px;
}

#answer-slots {
    background-color: #e0ffff;
    border: 2px dashed #00bfff;
}

#answer-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
}

#syllable-pool {
    background-color: #fffacd;
    border: 2px dashed #ffd700;
}

.syllable-slot {
    width: 80px;
    height: 60px;
    background-color: #e0ffff;
    border-radius: 8px;
}

.syllable {
    width: 80px;
    height: 60px;
    background-color: #ff6347;
    color: white;
    font-size: 1.8em;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 10px;
    cursor: grab;
    box-shadow: 0 4px #d44d33;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.syllable:active {
    cursor: grabbing;
    transform: translateY(2px);
    box-shadow: 0 2px #d44d33;
}

.sortable-ghost {
    background: #add8e6;
    opacity: 0.7;
}

hr {
    border: none;
    border-top: 2px solid #ccc;
    margin: 25px 0;
}

#feedback-message {
    margin-top: 15px;
    font-size: 1.5em;
    height: 30px;
    font-weight: bold;
}

.correct {
    color: #32cd32;
}

.incorrect {
    color: #dc143c;
}

#next-word-button {
    font-family: 'Lilita One', cursive;
    margin-top: 20px;
    padding: 15px 30px;
    font-size: 1.2em;
    border-radius: 10px;
    border: none;
    background-color: #32cd32;
    color: white;
    cursor: pointer;
    box-shadow: 0 4px #28a428;
    transition: all 0.2s ease;
}

#next-word-button:hover {
    background-color: #2fb82f;
}

#next-word-button:active {
    transform: translateY(2px);
    box-shadow: 0 2px #28a428;
}

#restart-button {
    font-family: 'Lilita One', cursive;
    margin-top: 20px;
    padding: 15px 30px;
    font-size: 1.2em;
    border-radius: 10px;
    border: none;
    background-color: #ff6347;
    color: white;
    cursor: pointer;
    box-shadow: 0 4px #d44d33;
    transition: all 0.2s ease;
}

#restart-button:hover {
    background-color: #e55a40;
}

#restart-button:active {
    transform: translateY(2px);
    box-shadow: 0 2px #d44d33;
}

.hidden {
    display: none;
}

#popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 20px;
    z-index: 100;
}

#popup-overlay.hidden {
    display: none;
}

#popup {
    text-align: center;
    background-color: white;
    padding: 30px 50px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

#popup h2 {
    color: #32cd32;
    font-size: 2em;
    margin-top: 0;
    margin-bottom: 15px;
}