body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f0f2f5;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
}

.container {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
    max-width: 600px;
    width: 100%;
}

h1 {
    color: #333;
    margin-bottom: 1.5rem;
}

.hangman-display {
    margin-bottom: 2rem;
}

svg {
    border: 1px solid #eee;
    background-color: #fff;
}

.scaffold {
    stroke: #333;
    stroke-width: 4;
}

.body-part {
    stroke: #e74c3c;
    stroke-width: 4;
    fill: none;
    display: none; /* Hidden initially */
}

.word-display {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 2rem;
    font-size: 2rem;
    font-weight: bold;
    min-height: 40px;
}

.letter-slot {
    border-bottom: 3px solid #333;
    width: 30px;
    text-align: center;
}

.keyboard {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: 0 auto;
}

.keyboard-row {
    display: flex;
    justify-content: center;
    gap: 6px;
}

.key {
    padding: 0;
    width: 36px;
    height: 40px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    background-color: #d3d6da;
    color: #000;
    border: none;
    border-radius: 4px;
    transition: background-color 0.2s;
    display: flex;
    justify-content: center;
    align-items: center;
}

.key:hover:not(:disabled) {
    background-color: #bbb;
}

.key:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.key.correct {
    background-color: #2ecc71;
    color: white;
}

.key.wrong {
    background-color: #e74c3c;
    color: white;
}

.message-area {
    margin-bottom: 1rem;
    height: 1.5rem;
    color: #e74c3c;
    font-weight: bold;
}

.restart-btn {
    margin-top: 1.5rem;
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1rem;
}

.restart-btn:hover {
    background-color: #2980b9;
}

