body {
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.container {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    padding: 20px;
    max-width: 600px;
    width: 100%;
}

header {
    text-align: center;
    margin-bottom: 20px;
}

h1 {
    color: #333;
    margin: 0;
}

.stats {
    display: flex;
    justify-content: space-around;
    margin-top: 10px;
}

.score, .timer {
    background-color: #4CAF50;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
}

main {
    margin-bottom: 20px;
}

.setup {
    text-align: center;
}

#category, #difficulty {
    padding: 5px;
    margin: 10px;
}

#start-btn {
    background-color: #2196F3;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

#start-btn:hover {
    background-color: #0b7dda;
}

.high-score {
    margin-top: 10px;
    font-weight: bold;
}

.game {
    text-align: center;
}

.chain-display {
    margin-bottom: 20px;
}

.chain {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    min-height: 50px;
    padding: 10px;
    background-color: #f9f9f9;
    border-radius: 5px;
}

.chain span {
    background-color: #e0e0e0;
    padding: 5px 10px;
    border-radius: 5px;
    display: inline-block;
    margin: 2px;
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

.input-section {
    margin-bottom: 20px;
}

#word-input {
    padding: 10px;
    font-size: 16px;
    width: 200px;
    margin: 10px;
}

.buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
}

#submit-btn {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

#submit-btn:hover {
    background-color: #45a049;
}

#hint-btn {
    background-color: #FF9800;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

#hint-btn:hover {
    background-color: #e68900;
}

.message {
    margin-top: 20px;
    font-weight: bold;
    min-height: 20px;
}

.message.error {
    color: red;
}

.message.success {
    color: green;
}

.message.info {
    color: blue;
}

footer {
    text-align: center;
    font-size: 14px;
    color: #666;
}