/* Skanimal status icons (SkanimalStatusIcons) and their key (SkanimalStatusLegend): small round chips, one per fact,
   on Team cards and in the pre-battle roster. No filters, no looping animation. */

.sk-status-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 3px;
    min-width: 0;
    max-width: 100%;
}

.sk-status {
    --tone: var(--sc-text-muted);
    display: inline-flex;
    flex: none;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-width: 20px;
    height: 20px;
    padding: 0 4px;
    border-radius: var(--sc-radius-pill);
    background: color-mix(in srgb, var(--tone) 22%, rgba(var(--sc-bg-rgb), 0.82));
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tone) 50%, transparent);
    color: var(--tone);
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.sk-status ion-icon {
    flex: none;
    font-size: 12px;
}

.sk-status.is-busy { --tone: var(--sc-azure, #4fb6ff); }
.sk-status.is-danger { --tone: var(--sc-danger); background: var(--sc-danger); color: #fff; }
.sk-status.is-warn { --tone: var(--sc-warning, #ffb340); }
.sk-status.is-good { --tone: var(--sc-success); }
.sk-status.is-gold { --tone: var(--sc-gold); }
.sk-status.is-love { --tone: #ff6fa0; }
.sk-status.is-info { --tone: var(--sc-purple); }
/* Glory: a warm flame chip with its number, the gold leaning towards fire */
.sk-status.is-glory {
    --tone: color-mix(in srgb, var(--sc-gold) 70%, #ff7a2f);
    background: linear-gradient(135deg, color-mix(in srgb, var(--sc-gold) 32%, rgba(var(--sc-bg-rgb), 0.82)), color-mix(in srgb, #ff7a2f 26%, rgba(var(--sc-bg-rgb), 0.82)));
}
.sk-status.is-more { --tone: var(--sc-text-muted); font-size: 10px; }

.sk-status-value {
    font-variant-numeric: tabular-nums;
}

/* The key: a small (i) button, and the grid it opens on a line of its own */
.sk-status-key-btn {
    display: inline-grid;
    flex: none;
    place-items: center;
    width: 28px;
    height: 28px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--sc-text-muted);
    font-size: 20px;
    cursor: pointer;
}

.sk-status-key-btn:hover,
.sk-status-key-btn.is-open {
    color: var(--sc-primary);
}

.sk-status-key {
    display: grid;
    flex: 1 0 100%;
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
    gap: 6px 10px;
    width: 100%;
    margin: 2px 0 4px;
    padding: 8px 10px;
    border: 1px solid var(--sc-line);
    border-radius: var(--sc-radius);
    background: var(--sc-surface);
    animation: sk-status-key-in 0.18s ease-out both;
}

.sk-status-key-item {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    font-size: 12px;
}

.sk-status-key-name {
    min-width: 0;
    overflow: hidden;
    color: var(--sc-text);
    text-overflow: ellipsis;
    white-space: nowrap;
}

@keyframes sk-status-key-in {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .sk-status-key { animation: none; }
}

/* On a Team card: along the stage's floor, left of the gem */
.mc-status {
    position: absolute;
    left: 10px;
    right: 56px;
    bottom: 10px;
    z-index: 2;
    gap: 4px;
}

.mc-status .sk-status {
    min-width: 24px;
    height: 24px;
    padding: 0 6px;
    font-size: 12px;
}

.mc-status .sk-status ion-icon {
    font-size: 14px;
}
