/* ==========================================
   SalmasFlix — Games · Battleship (Ocean Theme)
   Extracted from games.css in Phase 7.9 (2026-04-24, Wave 6).
   Originally at lines 2214-2379 of the monolith.

   Note: Battleship is NOT currently listed in the active games
   lineup (CLAUDE.md game table omits it) — `admin-app.js` only
   carries the string label. No `public/js/games/battleship.js`
   exists. This CSS is retained for historical / potential-rewrite
   reasons but is effectively dormant.

   Ocean theme uses literal #27ae60 (ship placed) / #e74c3c + rgba
   equivalents (hit / miss / invalid) and the blue gradient
   (#1a3a6b, #0d2456) because the blue-ocean IS the game's intrinsic
   visual identity, not themed chrome. Green / red are semantic
   (placed ok / hit warning) per the CLAUDE.md exception clause.

   Mobile-responsive block for `.bs-battle-grids`, `.bs-grid`, and
   `.bs-cell` stays inline in games.css (it lives inside the shared
   MOBILE RESPONSIVE - GAMES @media block alongside .cf-, .rockpaper-
   rules — pulling it apart would fragment the readability of that
   single breakpoint definition).
   ========================================== */

@layer features {


.bs-game-area {
    padding: var(--spacing-sm);
}

.bs-placement-section {
    text-align: center;
    max-width: 380px;
    margin: 0 auto;
}

.bs-ship-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin-bottom: var(--spacing-md);
}

.bs-ship-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    background: rgba(52, 152, 219, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.3);
    color: var(--text-secondary);
    transition: background 0.3s, background-color 0.3s, border-color 0.3s, box-shadow 0.3s, color 0.3s, filter 0.3s, opacity 0.3s, transform 0.3s;
}

.bs-ship-badge.placed {
    background: rgba(39, 174, 96, 0.15);
    border-color: rgba(39, 174, 96, 0.4);
    color: #27ae60;
}

.bs-ship-badge.current {
    background: rgba(var(--secondary-alt-rgb),0.15);
    border-color: rgba(var(--secondary-alt-rgb),0.4);
    color: var(--secondary-alt);
    box-shadow: 0 0 10px rgba(var(--secondary-alt-rgb),0.15);
}

.bs-battle-grids {
    display: flex;
    gap: var(--spacing-lg);
    justify-content: center;
    flex-wrap: wrap;
}

.bs-grid-section {
    text-align: center;
}

.bs-grid-label {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
    color: var(--text-secondary);
}

.bs-grid {
    display: grid;
    grid-template-columns: 24px repeat(10, 1fr);
    grid-template-rows: 24px repeat(10, 1fr);
    gap: 2px;
    background: linear-gradient(180deg, rgba(13, 36, 86, 0.6), rgba(0, 20, 50, 0.8));
    border: 2px solid rgba(52, 152, 219, 0.2);
    border-radius: var(--radius-md);
    padding: 4px;
    max-width: 360px;
    width: 100%;
}

.bs-grid-small {
    max-width: 220px;
}

.bs-grid-small .bs-cell {
    min-width: 16px;
    min-height: 16px;
    font-size: 0.55rem;
}

.bs-label {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: rgba(52, 152, 219, 0.6);
}

.bs-cell {
    aspect-ratio: 1;
    min-width: 24px;
    min-height: 24px;
    background: rgba(20, 50, 80, 0.5);
    border: 1px solid rgba(52, 152, 219, 0.12);
    border-radius: 3px;
    cursor: pointer;
    transition: background 0.2s, background-color 0.2s, border-color 0.2s, box-shadow 0.2s, color 0.2s, filter 0.2s, opacity 0.2s, transform 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.bs-cell:hover {
    background: rgba(52, 152, 219, 0.25);
    border-color: rgba(52, 152, 219, 0.4);
}

.bs-cell.ship {
    background: rgba(52, 152, 219, 0.35);
    border-color: rgba(52, 152, 219, 0.5);
    box-shadow: inset 0 0 6px rgba(52, 152, 219, 0.2);
}

.bs-cell.preview-valid {
    background: rgba(39, 174, 96, 0.4);
    border-color: rgba(39, 174, 96, 0.7);
    box-shadow: 0 0 6px rgba(39, 174, 96, 0.2);
}

.bs-cell.preview-invalid {
    background: rgba(231, 76, 60, 0.4);
    border-color: rgba(231, 76, 60, 0.7);
}

/* Phase 7.7: !important stripped — higher specificity than :hover
   alone and source-order wins over earlier .bs-cell sibling rules. */
.bs-cell.hit {
    background: rgba(231, 76, 60, 0.5);
    border-color: rgba(231, 76, 60, 0.7);
    animation: bs-explode 0.4s ease;
}

.bs-cell.miss {
    background: rgba(127, 140, 141, 0.2);
    color: rgba(255, 255, 255, 0.25);
}

.bs-cell.attack-cell:hover:not(.hit):not(.miss) {
    background: rgba(231, 76, 60, 0.25);
    border-color: rgba(231, 76, 60, 0.5);
    cursor: crosshair;
}

@keyframes bs-explode {
    0% {
        transform: scale(0.5);
        background: rgba(255, 200, 50, 0.8);
    }

    50% {
        transform: scale(1.2);
    }

    100% {
        transform: scale(1);
    }
}


} /* end @layer features */
