/* 常駐 UI(resident-ui.js)v0.36.0。規約: 1px の線・角丸なし・影なし・13px・余白 4〜8px */

/* ノードのタグの札(付けた時だけ・ノードの上の外側。ノードの大きさは変えない) */
.node > .gs-tag-chips { position: absolute; left: 0; bottom: 100%; margin-bottom: 2px; display: flex; flex-wrap: nowrap; gap: 2px; max-width: 100%; overflow: hidden; pointer-events: none; z-index: 2; }
.gs-tag-chip { display: inline-flex; align-items: center; gap: 2px; font-size: 11px; line-height: 1.3; padding: 0 4px; border: 1px solid var(--border, #4a4a4a); background: var(--bg, #2d2d2d); color: var(--text-muted, #a8a8a8); white-space: nowrap; }

/* エディターの「タグ」の欄 */
.gs-tags-sec { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.gs-tags-head { font-weight: 600; display: flex; align-items: baseline; gap: 8px; }
.gs-tags-head small { font-weight: 400; color: var(--text-muted, #a8a8a8); font-size: 11px; }
.gs-tags-list { display: flex; flex-wrap: wrap; gap: 4px; }
.gs-tags-list .gs-tag-chip { font-size: 12px; color: var(--text, #e0e0e0); }
.gs-tags-list .gs-tag-chip button { border: 0; background: transparent; color: var(--text-muted, #a8a8a8); padding: 0 2px; cursor: pointer; font: inherit; }
.gs-tags-list .gs-tag-chip button:hover { color: var(--text, #e0e0e0); }
.gs-tags-none { color: var(--text-muted, #a8a8a8); font-size: 12px; }
.gs-tags-row { display: flex; gap: 4px; }
.gs-tags-row input { flex: 1 1 auto; min-width: 0; font-size: 12px; }
.gs-tags-bulk { border-top: 1px solid var(--border, #4a4a4a); padding-top: 4px; display: flex; flex-direction: column; gap: 4px; color: var(--text-muted, #a8a8a8); font-size: 12px; }

/* EzUI の画面ノードの 常駐 の行 */
.ezb-res { display: flex; align-items: center; gap: 6px; font-size: 12px; min-width: 0; }
.ezb-res .ezb-chk { display: inline-flex !important; flex-direction: row !important; align-items: center; gap: 4px; white-space: nowrap; flex: 0 0 auto; width: auto !important; margin: 0; }
.ezb-res .ezb-chk input { width: auto !important; margin: 0; flex: 0 0 auto; }
.ezb-res .ezb-res-sum { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-muted, #a8a8a8); }
.ezb-res .ezb-res-edit { padding: 1px 6px; font-size: 12px; }
.ezb-res-ed { margin-top: 8px; border-top: 1px solid var(--border, #4a4a4a); padding-top: 4px; font-size: 13px; }
.ezb-res-ed-head { font-weight: 600; margin-bottom: 4px; }
.ezb-res-ed-t { width: 100%; border-collapse: collapse; }
.ezb-res-ed-t td { padding: 2px 6px; border-bottom: 1px solid var(--border, #4a4a4a); vertical-align: top; }
.ezb-res-ed-t td:first-child { width: 20px; color: var(--text-muted, #a8a8a8); }
.ezb-res-ed-btns { display: flex; gap: 4px; justify-content: flex-end; margin-top: 4px; }

/* 常駐 UI の割り当て(表)と 使う場所(規則)の窓 */
.gs-res-modal { position: fixed; inset: 0; z-index: 150010; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, 0.55); font: 13px/1.4 var(--font-ui, system-ui, "Segoe UI", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif); color: var(--text, #e0e0e0); }
#gs-res-rules { z-index: 150020; }
.gs-res-box { display: flex; flex-direction: column; width: min(1180px, calc(100vw - 24px)); max-height: calc(100vh - 24px); background: var(--surface, #353535); border: 1px solid var(--border, #4a4a4a); }
.gs-res-title { display: flex; align-items: center; gap: 8px; padding: 6px 8px; background: var(--bg, #2d2d2d); border-bottom: 1px solid var(--border, #4a4a4a); font-size: 14px; }
.gs-res-title .gs-res-muted { font-size: 12px; }
.gs-res-title > b, .gs-res-modal button { white-space: nowrap; flex: 0 0 auto; }
.gs-res-gap { flex: 1 1 auto; }
.gs-res-muted { color: var(--text-muted, #a8a8a8); font-size: 12px; }
.gs-res-pad { padding: 4px 8px; }
.gs-res-tools { display: flex; gap: 4px; align-items: center; padding: 4px 8px; border-bottom: 1px solid var(--border, #4a4a4a); }
.gs-res-scroll { overflow: auto; min-height: 0; flex: 1 1 auto; }
.gs-res-t { width: 100%; border-collapse: collapse; }
.gs-res-t th, .gs-res-t td { padding: 4px 8px; border-bottom: 1px solid var(--border, #4a4a4a); text-align: left; vertical-align: top; }
.gs-res-t th { background: var(--bg, #2d2d2d); font-weight: 600; position: sticky; top: 0; z-index: 1; white-space: nowrap; }
.gs-res-t .gs-res-c { width: 40px; text-align: center; }
.gs-res-t .gs-res-n { width: 64px; }
.gs-res-t .gs-res-n input { width: 56px; font-size: 12px; }
.gs-res-t .gs-res-where { min-width: 240px; }
.gs-res-t tr.gs-res-focus td { background: rgba(126, 232, 162, 0.10); }
.gs-res-t tr.gs-res-off td { color: var(--text-muted, #a8a8a8); }
.gs-res-modal button { padding: 2px 8px; border: 1px solid var(--border, #4a4a4a); border-radius: 0; background: transparent; color: var(--text, #e0e0e0); font: inherit; cursor: pointer; }
.gs-res-modal button:hover { background: rgba(255, 255, 255, 0.08); }
.gs-res-modal button.gs-res-primary { border-color: var(--accent, #7ee8a2); }
.gs-res-modal button.gs-res-link { border: 0; padding: 0; text-decoration: underline; font-weight: 600; text-align: left; }
.gs-res-modal input[type=text], .gs-res-modal input[type=number], .gs-res-modal select { font-size: 12px; max-width: 100%; box-sizing: border-box; }
.gs-res-rules td { font-size: 12px; }
.gs-res-chks { display: flex; flex-direction: column; max-height: 96px; overflow: auto; min-width: 110px; border: 1px solid var(--border, #4a4a4a); padding: 2px 4px; }
.gs-res-chks label { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.gs-res-cond { min-width: 180px; }
.gs-res-cond > * { display: block; width: 100%; margin-bottom: 2px; }
.gs-res-rules input[data-f="tags"] { width: 120px; }
.gs-res-foot { display: flex; gap: 4px; align-items: center; padding: 6px 8px; border-top: 1px solid var(--border, #4a4a4a); }

/* 実行情報「使っている常駐 UI」 */
.sim-res-table tr.sim-res-unused th, .sim-res-table tr.sim-res-unused td { opacity: 0.6; }
