/* Mini Crossword Game Styles */
.crossword-container {
    max-width: 500px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Grid */
.crossword-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 2px;
    max-width: 320px;
    margin: 1rem auto;
    aspect-ratio: 1;
    background: #333;
    border: 2px solid #333;
    border-radius: 4px;
}

.crossword-cell {
    position: relative;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    user-select: none;
    aspect-ratio: 1;
    transition: background-color 0.15s;
}

.crossword-cell.selected {
    background: #f7da21;
}

.crossword-cell.highlighted {
    background: #b8d4f0;
}

.crossword-cell.correct {
    background: #6aaa64;
    color: #fff;
}

.crossword-cell.revealed {
    background: #c9b458;
    color: #fff;
}

.cell-number {
    position: absolute;
    top: 2px;
    left: 3px;
    font-size: 0.55rem;
    font-weight: 600;
    color: #333;
    line-height: 1;
}

.cell-letter {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1;
}

/* Stats Row */
.game-stats-row {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    padding: 0.5rem 0;
    font-size: 0.95rem;
}

.stat {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.stat-value {
    font-weight: 700;
}

/* Clues */
.clues-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 1rem 0;
    font-size: 0.9rem;
}

.clue-section h3 {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #666;
    margin: 0 0 0.5rem 0;
    padding-bottom: 0.3rem;
    border-bottom: 2px solid #f7da21;
}

.clue-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.clue-item {
    padding: 0.35rem 0.4rem;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.15s;
    line-height: 1.3;
}

.clue-item:hover {
    background: #f0f0f0;
}

.clue-item.active {
    background: #f7da21;
    font-weight: 600;
}

.clue-item.solved {
    color: #888;
    text-decoration: line-through;
}

.clue-number {
    font-weight: 700;
    margin-right: 0.25rem;
}

/* Controls */
.game-controls {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

.game-btn {
    padding: 0.5rem 1rem;
    border: 2px solid #333;
    border-radius: 8px;
    background: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.game-btn:hover {
    background: #f7da21;
}

.game-btn:active {
    transform: scale(0.97);
}

.btn-check {
    background: #f7da21;
    border-color: #d4b800;
}

.btn-reveal {
    background: #e8e8e8;
}

/* Direction Toggle */
.direction-toggle {
    text-align: center;
    margin: 0.5rem 0;
}

.direction-btn {
    padding: 0.3rem 0.8rem;
    border: 1px solid #ccc;
    background: #f5f5f5;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 4px;
}

.direction-btn.active {
    background: #f7da21;
    border-color: #d4b800;
}

/* Completion Overlay */
.completion-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.completion-overlay.visible {
    display: flex;
}

.completion-box {
    background: #fff;
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    max-width: 340px;
    width: 90%;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.completion-emoji {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.completion-title {
    font-size: 1.5rem;
    margin: 0 0 0.25rem;
}

.completion-subtitle {
    color: #666;
    margin: 0 0 1rem;
    font-size: 0.9rem;
}

.completion-stats {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin: 1rem 0;
}

.completion-stat {
    text-align: center;
}

.completion-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
}

.completion-stat-label {
    font-size: 0.75rem;
    color: #888;
    text-transform: uppercase;
}

.completion-share-btn {
    display: inline-block;
    background: #f7da21;
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    margin: 0.5rem 0;
    transition: transform 0.1s;
}

.completion-share-btn:hover {
    transform: scale(1.03);
}

.completion-play-again {
    display: block;
    margin: 0.5rem auto 0;
    background: none;
    border: none;
    color: #666;
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: underline;
}

/* SEO Content */
.seo-content {
    max-width: 640px;
    margin: 2rem auto;
    padding: 0 1rem;
    color: #444;
    line-height: 1.7;
    font-size: 0.95rem;
}

.seo-content h2 {
    font-size: 1.3rem;
    color: #222;
    margin: 1.5rem 0 0.5rem;
}

.seo-content h3 {
    font-size: 1.1rem;
    color: #333;
    margin: 1.2rem 0 0.4rem;
}

.seo-content ul {
    padding-left: 1.5rem;
}

.seo-content li {
    margin-bottom: 0.3rem;
}

.seo-content a {
    color: #d4a800;
}

/* Mobile */
@media (max-width: 480px) {
    .crossword-grid {
        max-width: 280px;
    }

    .cell-letter {
        font-size: 1.2rem;
    }

    .cell-number {
        font-size: 0.5rem;
    }

    .clues-container {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .game-stats-row {
        font-size: 0.85rem;
        gap: 1rem;
    }

    .game-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }
}
