/**
 * modals.css — Modal overlays
 */

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background: #150b29;
    border: 2px solid var(--cc-player1);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 0 30px var(--cc-player1-glow);
}

.modal-titlebar {
    background: var(--cc-player1);
    color: var(--cc-bg);
    font-family: 'Press Start 2P', monospace;
    font-size: 10px;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--cc-bg);
    font-size: 16px;
    cursor: pointer;
    padding: 0 4px;
}

.modal-body {
    padding: 20px;
    font-family: 'Courier Prime', monospace;
    font-size: 13px;
    color: var(--cc-text);
    line-height: 1.6;
}

.modal-body h3 {
    font-family: 'Press Start 2P', monospace;
    font-size: 12px;
    color: var(--cc-player1);
    margin-bottom: 16px;
}

.modal-body h4 {
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    color: var(--cc-highlight);
    margin-top: 20px;
    margin-bottom: 10px;
}

.modal-body ul {
    margin-left: 20px;
    margin-bottom: 12px;
}

.modal-body li {
    margin-bottom: 6px;
}

.modal-footer {
    text-align: center;
    margin-top: 20px;
}

.modal-footer button {
    background: var(--cc-player1);
    color: var(--cc-bg);
    border: none;
    font-family: 'Press Start 2P', monospace;
    font-size: 10px;
    padding: 10px 24px;
    cursor: pointer;
    transition: all 0.15s;
}

.modal-footer button:hover {
    background: #ffffff;
    box-shadow: 0 0 20px var(--cc-player1-glow);
}

/* Game Over Modal */
.game-over-content {
    text-align: center;
}

.game-over-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.game-over-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 20px;
    margin-bottom: 12px;
}

.game-over-title.win {
    color: var(--cc-highlight);
    text-shadow: 0 0 15px var(--cc-highlight-glow);
}

.game-over-title.lose {
    color: var(--cc-player2);
    text-shadow: 0 0 15px var(--cc-player2-glow);
}

.game-over-message {
    font-family: 'Courier Prime', monospace;
    font-size: 14px;
    color: var(--cc-text-dim);
    margin-bottom: 20px;
}

/* Board diagram in instructions */
.board-diagram {
    background: var(--cc-bg);
    border: 1px solid var(--cc-cell-border);
    padding: 12px;
    margin: 12px 0;
    overflow-x: auto;
}

.board-diagram pre {
    font-family: 'Courier Prime', monospace;
    font-size: 11px;
    color: var(--cc-text);
    margin: 0;
}
