/* ===== MINES GAME STYLES ===== */

/* Main wrapper: grid top, controls bottom */
.mines-game-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 600px;
    margin: 30px auto;
    align-items: center;
}

/* ===== GRID PANEL ===== */
.mines-grid-panel {
    width: 100%;
    background: #0f1923;
    border-radius: 12px;
    padding: 20px;
}

.mines-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}

.mine-tile {
    height: 80px;
    background: #1e3448;
    border: 1px solid #2a4560;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, transform 0.12s;
    position: relative;
    font-size: 24px;
    user-select: none;
}

.mine-tile:hover:not(.revealed) {
    background: #26435e;
    transform: translateY(-2px);
}

.mine-tile.revealed-diamond {
    background: #0a2218;
    cursor: default;
    transform: none;
}

.mine-tile.revealed-mine {
    background: #3a0d0d;
    cursor: default;
    transform: none;
}

.mine-tile.revealed-fade {
    opacity: 0.35;
    cursor: default;
}

.mine-tile.selected-auto {
    border: 2px solid #35b5ef;
    background: #112233;
}

/* Diamond shape */
.diamond-icon {
    width: 34px;
    height: 34px;
    background: linear-gradient(135deg, #4cff6e, #00b843);
    clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
    box-shadow: 0 0 12px rgba(76,255,110,0.5);
}

/* Tooltip */
.tile-tooltip {
    position: absolute;
    top: -26px;
    left: 50%;
    transform: translateX(-50%);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 800;
    color: #fff;
    z-index: 20;
    pointer-events: none;
    white-space: nowrap;
}
.tooltip-green { background: #00b843; }
.tooltip-red   { background: #e74c3c; }

/* ===== CONTROL PANEL ===== */
.mines-control-panel {
    width: 100%;
    background: #0f1923;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.control-tabs {
    display: flex;
    background: #06111a;
    border-radius: 8px;
    overflow: hidden;
}

.tab-btn {
    flex: 1;
    padding: 10px;
    background: transparent;
    border: none;
    color: #5a7a8e;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.tab-btn.active {
    color: #35b5ef;
    background: #0f1923;
}

.ctrl-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ctrl-label {
    color: #5a7a8e;
    font-size: 0.78rem;
    font-weight: 600;
}

.bet-input-row {
    display: flex;
    background: #06111a;
    border-radius: 8px;
    overflow: hidden;
    height: 44px;
}

.bet-input-inner {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 10px;
}

.bet-input-inner input {
    background: transparent;
    border: none;
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
    width: 100%;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.bet-btns {
    display: flex;
    border-left: 1px solid #0b1a26;
}

.bet-btns button {
    background: #122030;
    border: none;
    border-left: 1px solid #0b1a26;
    color: #5a7a8e;
    padding: 0 9px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.15s;
}

.bet-btns button:hover {
    background: #1a3048;
    color: white;
}

.ctrl-input-box {
    background: #06111a;
    border-radius: 8px;
    height: 44px;
    display: flex;
    align-items: center;
    padding: 0 12px;
}

.ctrl-input-box input {
    background: transparent;
    border: none;
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    width: 100%;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.btn-mines-bet {
    width: 100%;
    padding: 14px;
    background: #00e701;
    color: #000;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 800;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.5px;
    margin-top: 4px;
    transition: opacity 0.2s, transform 0.1s;
}

.btn-mines-bet:hover { opacity: 0.88; }
.btn-mines-bet:active { transform: scale(0.98); }
.btn-mines-bet.btn-cashout { background: #e67e22; color: #fff; }
.btn-mines-bet.btn-auto-stop { background: #e74c3c; color: #fff; }

#auto-settings { display: flex; flex-direction: column; gap: 10px; }

@media (max-width: 680px) {
    .mines-game-wrapper { flex-direction: column; }
    .mines-control-panel { width: 100%; }
    .mine-tile { height: 58px; }
}

/* Fix mines grid collapse */
.game-right-panel .mines-grid {
    width: 100%;
    max-width: 450px;
    margin: 0 auto;
}
