/* styles/widgets/achievement-badges.css
 *
 * Extracted from styles/main.css during T4#20 (the May-2026
 * CSS-split refactor). Originally lived at lines 5151-5210
 * of main.css. Cascade order is preserved: main.css loads first
 * (themes + base + modal/tab/layout infra), then per-widget
 * files in alphabetical order via <link> tags in index.html.
 */

/* ── ACHIEVEMENT BADGES (Slice 5) ──────────────────────────────
   Tile grid; each tile is grey until earned, then it lights up
   with the badge's accent color. Hover reveals the full
   description via the title attribute. */
.badges-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
    gap: 8px;
    padding: 6px 0;
}
.badge-tile {
    --badge-color: var(--green);
    aspect-ratio: 1 / 1;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface2);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 8px 4px;
    overflow: hidden;
    opacity: 0.4;
    filter: grayscale(0.7);
    transition: opacity 0.2s, filter 0.2s, box-shadow 0.2s, border-color 0.2s;
    cursor: default;
}
.badge-tile-earned {
    opacity: 1;
    filter: none;
    background: color-mix(in oklab, var(--badge-color) 15%, var(--surface2));
    border-color: var(--badge-color);
    box-shadow: 0 0 8px color-mix(in oklab, var(--badge-color) 25%, transparent);
}
.badge-tile-icon {
    font-size: 26px;
    line-height: 1;
}
.badge-tile-name {
    font-size: 10px;
    color: var(--muted);
    text-align: center;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-break: break-word;
    max-width: 100%;
}
.badge-tile-earned .badge-tile-name { color: var(--text); font-weight: 600; }
.badge-tile-value {
    font-size: 11px;
    font-weight: 700;
    color: var(--badge-color);
    font-variant-numeric: tabular-nums;
}

