/* Windows Task Manager */
.tm-body { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 6px 8px 8px; background: #ece9d8; font: 11px Tahoma, Verdana, Arial, sans-serif; }
.tm-tabs { display: flex; gap: 2px; padding-left: 4px; }
.tm-tabs button {
    position: relative; top: 1px; padding: 3px 10px; cursor: pointer; font: inherit; color: #000;
    background: linear-gradient(180deg, #fff 0%, #ecebe5 100%); border: 1px solid #919b9c; border-bottom: 0; border-radius: 3px 3px 0 0;
}
.tm-tabs button[aria-selected="true"] { z-index: 1; padding-bottom: 5px; top: 0; background: #fcfcfe; border-top: 2px solid #e68b2c; }
.tm-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 8px; padding: 8px; background: #fcfcfe; border: 1px solid #919b9c; }
.tm-panel[hidden] { display: none; }
.tm-table-wrap { flex: 1; min-height: 0; overflow: auto; background: #fff; border: 1px solid #7f9db9; }
.tm-table { width: 100%; border-collapse: collapse; }
.tm-table th {
    position: sticky; top: 0; padding: 3px 6px; text-align: left; font-weight: normal;
    background: linear-gradient(180deg, #fff, #ebeadb); border-bottom: 1px solid #d6d2c2; border-right: 1px solid #d6d2c2;
}
.tm-table td { padding: 2px 6px; white-space: nowrap; }
.tm-table td img { width: 16px; height: 16px; margin-right: 5px; vertical-align: -3px; object-fit: contain; }
.tm-table tr { cursor: default; outline: none; }
.tm-table tbody tr.is-selected, .tm-table tbody tr:focus-visible { background: #316ac5; color: #fff; }
.tm-buttons { display: flex; justify-content: flex-end; gap: 6px; }
.tm-buttons .xp-btn { font-size: 11px; padding: 3px 12px; }
.tm-buttons .xp-btn:disabled { color: #aca899; cursor: default; }
.tm-grid { display: grid; grid-template-columns: 76px 1fr; gap: 8px; flex: 1; min-height: 0; }
.tm-grid fieldset, .tm-totals {
    min-width: 0; padding: 4px 6px 6px; border: 1px solid #d0d0bf; border-radius: 3px;
    display: flex; flex-direction: column; align-items: stretch;
}
.tm-grid legend, .tm-totals legend { padding: 0 3px; color: #0046d5; }
.tm-meter {
    position: relative; flex: 1; min-height: 50px; background: #000;
    background-image: repeating-linear-gradient(0deg, #004d00 0 2px, transparent 2px 4px);
    background-size: 60% 100%; background-position: center; background-repeat: no-repeat;
}
.tm-meter::after {
    content: ""; position: absolute; left: 20%; right: 20%; bottom: 0; height: var(--level, 0%);
    background: repeating-linear-gradient(0deg, #00ff00 0 2px, transparent 2px 4px);
    transition: height 0.3s;
}
.tm-meter.mem::after { background: repeating-linear-gradient(0deg, #ffff00 0 2px, transparent 2px 4px); }
.tm-grid fieldset > span { display: block; padding: 2px 0; text-align: center; background: #000; color: #00ff00; font-variant-numeric: tabular-nums; }
.tm-grid canvas { flex: 1; width: 100%; min-height: 50px; display: block; background: #000; }
.tm-totals { flex-direction: row; gap: 8px; }
