/* Compact, non-modal command group; the map remains available for orders. */
footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed),.kids footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed){grid-template-rows:40px 214px 36px 18px}
footer#commandDock[data-panel=units][data-residents=selection] .unitbar{height:214px;max-height:214px}
#selectionGroupPane{display:flex;flex:1;flex-direction:column;gap:7px;min-height:0;min-width:0}
#selectionGroupPane[hidden],.resident-toolbar #showSelectionGroup[hidden]{display:none}
.selection-group-heading{display:flex;justify-content:space-between;align-items:center;gap:8px;font-size:12px;color:#dacb9d;flex-shrink:0}
.selection-group-heading strong{color:#ffe3a1;font-size:14px}
.selection-filter-scroll{display:flex;gap:4px;min-width:0;flex:0 0 38px}
.selection-filter-scroll>button{min-width:28px;padding:0 5px;border:1px solid #b39c69;background:#354c3b;color:#ffecb5}
.selection-filter-scroll>button:disabled{opacity:.4}
#selectionProfessions{display:flex;gap:5px;min-width:0;flex:1;overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;scrollbar-color:#d9b66e #243c2e;overscroll-behavior:contain;touch-action:pan-x}
#selectionProfessions button{flex:0 0 auto;white-space:nowrap;min-height:34px;padding:5px 10px;font:13px system-ui;background:#38503e;color:#f8e6b9;border:1px solid #ac9b6c;border-radius:6px}
#selectionProfessions button[aria-pressed=true]{background:#f4d796;color:#253d2e;border-color:#fff0bf;font-weight:700}
#selectionGroupRoster{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));grid-auto-rows:58px;align-content:start;gap:6px;overflow-y:auto;min-height:0;flex:1;scrollbar-width:thin;scrollbar-color:#d9b66e #243c2e;overscroll-behavior:contain}
#selectionGroupRoster .selection-person{display:grid;grid-template-columns:28px minmax(0,1fr) 42px;align-items:center;gap:7px;padding:5px 8px;margin:0;min-width:0;background:linear-gradient(#f7e6b9,#e5cb90);border:1px solid #f7df9c;border-radius:7px;text-align:left;color:#263e2f;min-height:54px}
.selection-person img{width:27px;height:44px;object-fit:contain}
.selection-person strong,.selection-person small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.selection-person strong{font:700 13px system-ui}.selection-person small{font:11px system-ui;margin-top:3px;color:#42533d}
.selection-health{text-align:right}.selection-health progress{width:42px;height:7px;accent-color:#4c7a3c}.selection-health .low-health{accent-color:#b4412d}
#selectionGroupHint{margin:0;font:12px/1.3 system-ui;color:#e1d5b1;flex:0 0 auto}
.selection-empty{grid-column:1/-1;margin:6px;font-size:13px;line-height:1.5;color:#f1dfac}
#selectionGroupPane button:focus-visible{outline:3px solid #fff5d3;outline-offset:-3px}
@media(max-width:760px){footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed),.kids footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed){grid-template-rows:44px 214px 34px}.selection-group-heading{flex-wrap:wrap;gap:3px}.selection-group-heading strong{font-size:13px}.selection-group-heading span{font-size:11px}#selectionGroupRoster{grid-template-columns:repeat(auto-fill,minmax(158px,1fr))}.selection-person img{width:22px}#selectionGroupRoster .selection-person{grid-template-columns:22px minmax(0,1fr) 36px;gap:4px;padding:4px}.selection-health progress{width:36px}#selectionGroupHint{font-size:11px}footer[data-panel=units][data-residents=selection] .dock-context{display:none}}
@media(max-height:570px){footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed),.kids footer#commandDock[data-panel=units][data-residents=selection]:not(.dock-collapsed){grid-template-rows:36px 166px 29px}footer#commandDock[data-panel=units][data-residents=selection] .unitbar{height:166px;max-height:166px}#selectionGroupPane{gap:4px}.selection-group-heading span{display:none}#selectionGroupHint{font-size:10px}.selection-filter-scroll{flex-basis:34px}}
