/* styles.css */


button {
    margin: 5px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(30px, 1fr));
    gap: 2px;
    margin: 20px 0;
}

.grid-cell {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #ccc;
    background-color: #ffffff;
    font-weight: bold;
}

.grid-cell.highlight {
    background-color: #ffeb3b;
}

.solution {
    display: none;
    margin-top: 20px;
    padding: 10px;
    border: 1px solid #007bff;
    background-color: #e7f1ff;
}

/* Add styles for found words and found grid cells */
.found-word {
    font-weight: bold;
    font-style: italic;
    background-color: var(--found-color, #ffe066);
    transition: background 0.3s;
}
.found-cell {
    border: 1px solid #ccc !important; /* Match .ltr border */
    background-color: var(--found-color, #ffe066) !important;
    color: #222;
    box-sizing: border-box;
    outline: none;
    /* Remove extra border width and padding that could cause misalignment */
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
    /* Ensure width/height matches .ltr */
    width: auto;
    height: auto;
    display: inline-block;
}

.ltr {
    /* Ensure .ltr and .found-cell have the same box model */
    box-sizing: border-box;
    padding: 5px 10px;
    border-radius: 5px;
    border: 1px solid lightgray;
    background-color: #f5f4f2;
    font-weight: bold;
    width: auto;
    height: auto;
    display: inline-block;
}

.selected {
    outline: 2px dashed #007bff;
    background-color: #e6f2ff;
}

#wordsFoundCounter {
    font-weight: bold;
    color: #198754;
    margin-bottom: 1em;
}

