#stratego-wrapper {
    max-width: 520px;
    margin: 20px auto;
    font-family: Arial, sans-serif;
}

#stratego-controls {
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}


#stratego-message {
    font-weight: bold;
    min-height: 1.0em;
	font-size: 14px;
}

.stratego-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    border: 2px solid #333;
}

.stratego-cell {
    width: 50px;
    height: 50px;
    border: 1px solid #555;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    cursor: pointer;
    font-size: 14px;
    user-select: none;
}

.stratego-cell.lake {
    background-color: #4a90e2;
    cursor: default;
}

.stratego-cell.selected {
    outline: 3px solid #f1c40f;
}

#stratego-newgame {
	width: 150px;
    padding: 6px 12px;
    background-color: #126724;
    color: #fff;
    border: none;
    border-radius: 16px;
    cursor: pointer;
	margin-right: 10px;
}

#stratego-newgame:hover {
    background-color: #2c3e50;
}

/* Base for any piece (player or AI) */
.stratego-piece {
    width: 44px;
    height: 44px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;          /* allow badge to stick out */
    box-shadow: 0 0 3px rgba(0,0,0,0.5);
    z-index: 1;
}

/* Make THE IMAGE circular instead of the container */
.stratego-piece img {
    width: 100%;
    height: 100%;
    border-radius: 50%;         /* circle comes from the image */
    object-fit: cover;
    display: block;
    z-index: 1;
}

/* Rank badge */
.stratego-rank-badge {
    position: absolute;
    top: -4px;                  /* now can be slightly outside */
    right: -4px;
    background: rgba(0,0,0,0.85);
    color: #fff;
    font-size: 11px;
    padding: 1px 4px;
    border-radius: 999px;
    font-weight: bold;
    line-height: 1;
    z-index: 2;                 /* above the image */
    pointer-events: none;
}

#stratego-game-area {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

#captured-wrapper {
    width: 160px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.piece-sm {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
}

.piece-sm img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.badge-sm {
    position: absolute;
    top: -2px;
    right: -2px;
    background: rgba(0,0,0,0.85);
    color: #fff;
    font-size: 9px;
    padding: 1px 3px;
    border-radius: 5px;
}

.stratego-piece-reveal {
    animation: reveal-pulse 0.3s ease-out;
}

@keyframes reveal-pulse {
    from { transform: scale(0.8); opacity: 0.2; }
    to   { transform: scale(1); opacity: 1; }
}
