h1 {
    text-align: center;
    margin-bottom: 10px;
    font-size: 2em;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}
.subtitle {
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.1em;
    opacity: 0.9;
}
.theme-hint {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: center;
}
.theme-hint h3 {
    color: #ffd700;
    margin-bottom: 5px;
}
.found-words {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 20px;
}
.found-word {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    transition: all 0.3s;
}
.found-word.found {
    background: #4caf50;
    transform: scale(1.05);
}
.grid-container {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}
.grid {
    display: grid;
    gap: 4px;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px;
    border-radius: 10px;
    grid-template-columns: repeat(var(--grid-cols, 6), 1fr);
}
.cell {
    width: clamp(35px, 12vw, 48px);
    height: clamp(35px, 12vw, 48px);
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    font-weight: bold;
    color: #333;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s;
}
.cell:hover {
    background: #fff;
    transform: scale(1.05);
}
.cell.selected {
    background: #ffd700;
    color: #333;
}
.cell.found {
    background: #4caf50;
    color: white;
}
.cell.spangram {
    background: #e91e63;
    color: white;
}
.current-word {
    text-align: center;
    font-size: 1.5em;
    margin-bottom: 15px;
    min-height: 40px;
    color: #ffd700;
    font-weight: bold;
}
.buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
button {
    padding: 12px 25px;
    font-size: 1em;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}
.btn-clear {
    background: #f44336;
    color: white;
}
.btn-submit {
    background: #4caf50;
    color: white;
}
.btn-hint {
    background: #ff9800;
    color: white;
}
button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}
.progress {
    text-align: center;
    font-size: 1.2em;
    margin-bottom: 20px;
}
.message {
    text-align: center;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: bold;
    display: none;
}
.message.success {
    background: #4caf50;
    display: block;
}
.message.error {
    background: #f44336;
    display: block;
    animation: shake 0.5s;
}
@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-10px);
    }
    75% {
        transform: translateX(10px);
    }
}
.next-button {
    display: none;
    margin: 20px auto;
    padding: 15px 40px;
    font-size: 1.3em;
    background: linear-gradient(135deg, #ffd700, #ffaa00);
    color: #333;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    animation: pulse 2s infinite;
}
.next-button.visible {
    display: block;
}
@keyframes pulse {
    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 20px 10px rgba(255, 215, 0, 0);
    }
}
.instructions {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    font-size: 0.9em;
}
.instructions h4 {
    margin-bottom: 10px;
    color: #ffd700;
}
.instructions ul {
    margin-left: 20px;
}
.instructions li {
    margin-bottom: 5px;
}
.validation-error {
    background: #ff5722;
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: none;
}
.validation-error.visible {
    display: block;
}
.validation-error ul {
    margin-left: 20px;
    margin-top: 10px;
}
