/* DEV-TOOLS:START */
.developer-mode-root { height: 100%; overflow: auto; padding: 8px; background: #c0c0c0; color: #111; font: 13px var(--w95-font); box-sizing: border-box; }
.dev-toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding-bottom: 8px; border-bottom: 1px solid #808080; }
.dev-app-heading { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; padding: 4px 6px; color: #000080; background: #c7d9f7; border: 1px solid #6f86ad; }
.dev-app-heading strong { font-size: 16px; }
.dev-app-heading span { font-size: 12px; color: #34445e; }
.dev-runtime-heading { color: #222; background: #d4d0c8; border-color: #808080; }
.dev-runtime-heading span { color: #444; }
.dev-app-section { padding: 6px; border: 1px solid #808080; background: #d4d0c8; }
.dev-app-section + .dev-app-section { margin-top: 8px; }
.dev-editor-window-heading { display: flex; align-items: baseline; gap: 10px; margin-bottom: 6px; padding: 4px 6px; border-bottom: 1px solid #808080; }
.dev-editor-window-heading strong { color: #000080; font-size: 15px; }
.dev-editor-window-heading span { color: #555; font-size: 11px; }
.dev-database-section { background: #c7d9f7; border-color: #6f86ad; }
.dev-debugger-section { background: #d4d0c8; }
.dev-app-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(105px, 1fr)); gap: 8px; }
.dev-app-icon { display: flex; min-height: 76px; align-items: center; justify-content: center; flex-direction: column; gap: 4px; padding: 5px; text-align: center; cursor: default; user-select: none; border: 1px solid transparent; }
.dev-app-icon:hover, .dev-app-icon:focus { outline: 1px dotted #111; background: rgba(255, 255, 255, .35); }
.dev-app-icon-data { color: #000080; }
.dev-app-icon-runtime { color: #222; }
.dev-app-icon-mature { color: #222; background: #d4d0c8; border-color: #808080; }
.dev-app-icon-glyph { font-size: 28px; line-height: 30px; }
.dev-btn { margin: 2px 0; padding: 3px 8px; min-height: 24px; }
.dev-status { margin: 8px 0; padding: 5px; background: #ffffe1; border: 1px solid #808080; }
.dev-status.dev-error { color: #900; background: #ffe0e0; }
.dev-panel { display: grid; gap: 8px; }
/* Data editors use a blue tint; runtime state tools stay neutral. */
.dev-panel.dev-data-panel { padding: 8px; background: #c7d9f7; border: 1px solid #6f86ad; }
.dev-panel.dev-data-panel .dev-section,
.dev-panel.dev-data-panel .dev-ie-sec,
.dev-panel.dev-data-panel .dev-qa-entry { background: #dce8fb; border-color: #8da4c8; }
.dev-panel.dev-runtime-panel .dev-section,
.dev-panel.dev-runtime-panel .dev-ie-sec { background: transparent; border-color: transparent; box-shadow: none; }
.dev-section { padding: 8px; background: #d4d0c8; border: 1px solid #808080; box-shadow: inset 1px 1px #fff; }
.dev-section h3 { margin: 0 0 8px; font-size: 14px; }
.dev-section label { display: inline-flex; align-items: center; gap: 4px; margin: 3px 8px 3px 0; }
.dev-section input, .dev-section select { box-sizing: border-box; min-height: 23px; }
.dev-section input[type="number"] { width: 74px; }
.dev-textarea { display: block; width: 100%; box-sizing: border-box; resize: vertical; font: 12px var(--w95-font); padding: 6px; border: 2px inset #eee; background: #fff; }
.dev-save-input { min-height: 58px; }
.dev-structured-root { display: flex; flex-direction: column; gap: 6px; min-height: 100%; }
.dev-structured-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; padding-bottom: 6px; border-bottom: 1px solid #8da4c8; }
.dev-structured-toolbar strong { margin-right: auto; color: #000080; }
.dev-structured-description { margin: 0; font-size: 12px; }
.dev-structured-fields { display: grid; gap: 8px; }
.dev-structured-field { display: grid; gap: 4px; }
.dev-structured-field > span { font-weight: 600; font-size: 12px; }
.dev-structured-field input { min-height: 23px; border: 2px inset #eee; padding: 2px 4px; box-sizing: border-box; }
.dev-keyword-table input, .dev-keyword-table textarea { width: 100%; box-sizing: border-box; }
.dev-keyword-table th:nth-child(1) { width: 150px; }
.dev-keyword-table th:nth-child(3) { width: 90px; }
.dev-current-file { font: bold 16px var(--w95-font); color: #003399; }
.dev-table { width: 100%; border-collapse: collapse; background: #fff; }
.dev-table th, .dev-table td { border: 1px solid #808080; padding: 4px; text-align: left; }
.dev-inventory-add { margin-bottom: 8px; }
.dev-qa-list { display: grid; gap: 8px; margin: 8px 0; }
.dev-qa-entry { padding: 7px; background: #fff; border: 2px outset #ddd; }
.dev-qa-entry header { display: flex; align-items: center; gap: 5px; margin-bottom: 6px; color: #003399; }
.dev-qa-entry header .dev-btn { margin-left: auto; }
.dev-qa-entry select { max-width: 190px; }
.dev-qa-entry label { display: flex; align-items: flex-start; width: 100%; margin: 5px 0; }
.dev-qa-entry textarea { flex: 1; min-height: 52px; resize: vertical; font: 12px var(--w95-font); }
.dev-qa-entry .dev-checkbox-label { align-items: center; }

/* DEV-TOOLS:END */

/* DEV-TOOLS:START */
/* ── shared tool button style ─────────────────────────────────────────── */
.dev-btn-tool { background: #1a1a6e; color: #fff; border-color: #4040b0; }
.dev-btn-tool:hover { background: #2828a0; }
.dev-btn-data { background: #1a1a6e; color: #fff; border-color: #4040b0; }
.dev-btn-data:hover { background: #2828a0; }
.dev-btn-runtime { background: #d4d0c8; color: #111; border-color: #808080; }
.dev-btn-runtime:hover { background: #e4e0d8; }
.dev-btn-danger { background: #c00000; color: #fff; border-color: #800000; }
.dev-btn-danger:hover { background: #e00000; }
.dev-ded-root { padding: 8px; background: #c7d9f7; border: 1px solid #6f86ad; }
.dev-ded-header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; }
.dev-ded-header strong { font-size: 14px; }
.dev-ded-header span { color: #34445e; font-size: 11px; flex: 1 1 240px; }
.dev-ded-header > div { flex-basis: 100%; }
.dev-ded-toolbar { display: flex; flex-wrap: wrap; align-items: end; gap: 6px; margin-bottom: 8px; }
.dev-ded-list { display: grid; gap: 8px; }
.dev-ded-card { background: #e7efff; border: 1px solid #8da4c8; padding: 8px; }
.dev-ded-card.nested { margin-top: 6px; background: #f2f6ff; }
.dev-ded-card-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.dev-ded-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 6px 10px; }
.dev-ded-field { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dev-ded-field > span, .dev-ded-subtitle, .dev-ded-tags > label { font-size: 11px; color: #28384f; }
.dev-ded-field input, .dev-ded-field select { box-sizing: border-box; min-height: 23px; width: 100%; border: 2px inset #eee; padding: 2px 4px; font-size: 12px; background: #fff; }
.dev-ded-check { display: flex; align-items: center; gap: 4px; min-height: 23px; font-size: 12px; }
.dev-ded-inline { display: flex; align-items: end; gap: 5px; margin: 4px 0; }
.dev-ded-inline .dev-ded-field { flex: 1; }
.dev-ded-tags { margin-top: 6px; }

/* ══════════════════════════════════════════════════════════════════════════
   ITEM EDITOR TAB
══════════════════════════════════════════════════════════════════════════ */
.dev-ie-root { display:flex; flex-direction:column; height:100%; min-height:0; }
.dev-ie-toolbar { display:flex; flex-wrap:wrap; gap:4px; padding:4px 0 6px; border-bottom:1px solid #808080; }
.dev-ie-main { display:flex; flex:1; min-height:0; gap:0; overflow:hidden; }
.dev-ie-sidebar { width:200px; min-width:160px; flex-shrink:0; border-right:1px solid #808080; display:flex; flex-direction:column; overflow:hidden; }
.dev-ie-sidebar-hd { display:flex; gap:4px; padding:4px; border-bottom:1px solid #aaa; }
.dev-ie-sidebar-hd input { flex:1; min-height:23px; border:2px inset #eee; padding:2px 4px; font-size:12px; }
.dev-ie-item-list { flex:1; overflow-y:auto; }
.dev-ie-item-row { display:flex; align-items:center; padding:5px 7px; cursor:pointer; border-bottom:1px solid #e0e0e0; font-size:12px; }
.dev-ie-item-row:hover { background:#d8e8ff; }
.dev-ie-item-row.active { background:#000080; color:#fff; }
.dev-ie-item-row.active div { color:#fff !important; }
.dev-ie-editor { flex:1; overflow-y:auto; min-width:0; }
.dev-ie-sec { margin:6px 8px; padding:8px; background:#d4d0c8; border:1px solid #808080; box-shadow:inset 1px 1px #fff; }
.dev-ie-sec h3 { margin:0 0 8px; font-size:13px; }
.dev-ie-row { display:flex; flex-wrap:wrap; gap:10px; margin-bottom:4px; }
.dev-ie-field { display:flex; flex-direction:column; gap:3px; flex:1; min-width:120px; font-size:12px; }
.dev-ie-field label { font-size:11px; color:#444; font-weight:600; }
.dev-ie-field input, .dev-ie-field select, .dev-ie-field textarea { min-height:23px; border:2px inset #eee; padding:2px 4px; font-size:12px; box-sizing:border-box; width:100%; }
.dev-ie-tags { display:flex; flex-wrap:wrap; gap:4px; margin-bottom:4px; }
.dev-ie-tag { display:inline-flex; align-items:center; gap:3px; padding:2px 6px; background:#e8e8ff; border:1px solid #9999cc; border-radius:3px; font-size:11px; }
.dev-ie-tag.kw { background:#e8ffe8; border-color:#66aa66; }
.dev-ie-tag button { border:none; background:none; cursor:pointer; padding:0 2px; color:#666; line-height:1; font-size:10px; }
.dev-ie-tag button:hover { color:#c00; }

/* ══════════════════════════════════════════════════════════════════════════
   DIALOGUE NODE EDITOR TAB
══════════════════════════════════════════════════════════════════════════ */
.dev-de-root { display:flex; flex-direction:column; height:100%; min-height:0; }
.dev-blueprint-window .win95-window-body { overflow:hidden; padding:2px; }
.dev-blueprint-window .dev-de-root { height:100%; min-height:0; }
.dev-de-header { display:flex; flex-wrap:wrap; gap:4px; padding:4px 0 6px; border-bottom:1px solid #808080; }
.dev-de-main { display:flex; flex:1; min-height:0; overflow:hidden; }

/* sidebar */
.dev-de-sidebar { width:160px; min-width:140px; flex-shrink:0; border-right:1px solid #808080; display:flex; flex-direction:column; overflow:hidden; }
.dev-de-sidebar-tools { display:flex; flex-direction:column; gap:3px; padding:4px; border-bottom:1px solid #808080; }
.dev-de-sidebar-tools .dev-btn { width:100%; }
.dev-de-phase-tabs { display:flex; border-bottom:1px solid #808080; }
.dev-de-ptab { flex:1; padding:4px; text-align:center; cursor:pointer; font-size:12px; font-weight:600; background:#c0c0c0; border-bottom:2px solid transparent; }
.dev-de-ptab.active { background:#fff; border-bottom-color:#000080; color:#000080; }
.dev-de-ptab:hover { background:#d8e8ff; }
.dev-de-sb-sec { padding:4px; }
.dev-de-sb-title { font-size:11px; font-weight:700; color:#000080; padding:4px 2px 2px; display:flex; align-items:center; justify-content:space-between; }
.dev-de-sb-add { border:1px outset #ccc; background:#c0c0c0; cursor:pointer; padding:0 6px; font-size:13px; line-height:18px; }
.dev-de-sb-add:hover { background:#a0c0ff; }
.dev-de-sb-day { padding:4px 8px; font-size:12px; cursor:pointer; border-bottom:1px solid #e0e0e0; }
.dev-de-sb-day:hover { background:#d8e8ff; }
.dev-de-sb-day.active { background:#000080; color:#fff; }
.dev-de-sb-item { padding:4px 8px; font-size:12px; cursor:pointer; border-bottom:1px solid #e0e0e0; display:flex; align-items:center; justify-content:space-between; }
.dev-de-sb-item:hover { background:#d8e8ff; }
.dev-de-sb-item.active { background:#000080; color:#fff; }
.dev-de-sb-del { border:none; background:none; cursor:pointer; color:#888; font-size:11px; padding:0 2px; }
.dev-de-sb-del:hover { color:#c00; }
.dev-de-sb-actions { display:inline-flex; gap:2px; margin-left:4px; }
.dev-de-sb-copy { border:none; background:none; cursor:pointer; color:#08752d; font-size:11px; padding:0 2px; }
.dev-de-sb-copy:hover { color:#000080; }
.dev-de-sb-empty { font-size:11px; color:#aaa; padding:4px 8px; }

/* canvas */
.dev-de-canvas-wrap { flex:1; display:flex; flex-direction:column; min-width:0; overflow:hidden; }
.dev-de-canvas-toolbar { display:flex; flex-wrap:wrap; gap:4px; padding:4px 6px; background:#d0d0d0; border-bottom:1px solid #808080; }
.dev-de-node-type-label { display:inline-flex; align-items:center; gap:4px; padding:2px 3px; font-size:11px; }
.dev-de-node-type { min-height:24px; border:2px inset #eee; font-size:11px; }
.dev-de-canvas-container { flex:1; position:relative; overflow:auto; background:#f0f0f8; cursor:default; }
.dev-de-canvas-content { position:relative; flex:none; width:2000px; height:1200px; }
.dev-de-selection-box { position:absolute; z-index:20; pointer-events:none; border:1px dashed #000080; background:rgba(0,0,128,.12); }
.dev-de-zoom-tools { display:inline-flex; align-items:center; gap:3px; margin-left:auto; }
.dev-de-zoom-tools span { min-width:42px; text-align:center; font-size:11px; }

/* nodes */
.dev-de-node { position:absolute; width:185px; min-height:90px; background:#fff; border:2px outset #ccc; box-shadow:2px 2px 4px rgba(0,0,0,.15); cursor:pointer; user-select:none; font-size:12px; }
.dev-de-node.selected { border-color:#000080; box-shadow:0 0 0 2px #000080; }
.dev-de-node.start { border-color:#cc6600; }
.dev-de-node-hd { padding:3px 6px; color:#fff; font-size:11px; font-weight:700; display:flex; justify-content:space-between; align-items:center; }
.dev-de-node-link { border:none; background:rgba(255,255,255,.25); cursor:pointer; color:#fff; padding:0 4px; font-size:11px; border-radius:2px; }
.dev-de-node-link:hover { background:rgba(255,255,255,.5); }
.dev-de-node-body { padding:4px 6px; color:#333; line-height:1.4; min-height:20px; word-break:break-all; }
.dev-de-node-options { padding:2px 6px; border-top:1px solid #ddd; background:#fafafa; }
.dev-de-node-opt { position:relative; display:flex; align-items:center; min-height:18px; padding-right:13px; color:#555; font-size:10px; white-space:nowrap; }
.dev-de-node-opt > span:first-child { min-width:0; overflow:hidden; text-overflow:ellipsis; }
.dev-de-option-pin { position:absolute; right:-9px; display:inline-flex; align-items:center; justify-content:center; width:15px; height:15px; border:1px solid #000080; border-radius:50%; background:#d8d8ff; color:#000080; font-size:9px; font-weight:bold; cursor:crosshair; user-select:none; z-index:2; }
.dev-de-option-pin:hover { background:#ffcc66; border-color:#cc6600; color:#000; }
.dev-de-node-ft { padding:2px 6px 4px; display:flex; gap:4px; flex-wrap:wrap; }
.dev-de-nbadge { background:#e8e8ff; border:1px solid #9999cc; border-radius:3px; font-size:10px; padding:1px 4px; color:#333; }
.dev-de-port-layer { position:absolute; inset:0; pointer-events:none; }
.dev-de-port-row { position:absolute; height:17px; line-height:17px; width:100%; display:flex; align-items:center; pointer-events:none; }
.dev-de-port-row.input { justify-content:flex-start; padding-left:0; }
.dev-de-port-row.output { justify-content:flex-end; padding-right:0; }
.dev-de-port-label { color:#555; font-size:9px; max-width:80px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.dev-de-port-pin { width:11px; height:11px; margin:0 -7px; border:2px solid #b00000; border-radius:50%; background:#ffd0d0; pointer-events:auto; cursor:crosshair; z-index:3; box-sizing:border-box; }
.dev-de-port-pin[data-kind="flow"] { background:#ffd0d0; border-color:#b00000; }
.dev-de-port-pin[data-kind="value"] { background:#c8f0d0; border-color:#08752d; }
.dev-de-port-pin:hover { background:#ffcc66 !important; border-color:#cc6600 !important; }
.dev-de-input-row { display:flex; align-items:center; gap:3px; margin:3px 0; font-size:11px; }
.dev-de-input-row label { width:65px; overflow:hidden; text-overflow:ellipsis; }
.dev-de-input-row em { color:#777; font-style:normal; }
.dev-de-input-mode, .dev-de-input-source, .dev-de-input-value { min-width:0; flex:1; min-height:21px; border:2px inset #eee; font-size:11px; }
.dev-de-input-ref { color:#075; font-size:10px; }
.dev-de-port-summary { margin-top:5px; color:#555; font-size:11px; }
.dev-de-connection-editor { border-top:1px solid #808080; }
.dev-de-output-row { display:flex; align-items:center; gap:4px; margin:3px 0; font-size:11px; }
.dev-de-output-row label { width:65px; overflow:hidden; text-overflow:ellipsis; color:#a00000; }
.dev-de-output-row select { flex:1; min-width:0; min-height:21px; border:2px inset #eee; font-size:11px; }
.dev-de-input-help, .dev-de-ed-help { color:#666; font-size:10px; line-height:1.35; margin-top:3px; }
.dev-de-input-text { min-height:42px; resize:vertical; }
.dev-de-port-chip { display:inline-block; margin:2px; padding:1px 4px; border:1px solid #888; border-radius:3px; }
.dev-de-port-chip.flow { background:#ffd0d0; border-color:#b00000; color:#8a0000; }
.dev-de-port-chip.value { background:#dff5e5; }
.dev-de-no-ports { color:#999; font-size:11px; }

/* activity editor workspace */
.dev-activity-workspace { display:flex; flex-direction:column; height:100%; min-height:0; }
.dev-activity-title { color:#000080; font-size:14px; padding:3px 8px 3px 0; }
.dev-activity-help { color:#555; font-size:11px; align-self:center; margin-left:auto; }
.dev-activity-tables { flex:1; min-height:0; overflow:auto; display:grid; grid-template-columns:repeat(2,minmax(320px,1fr)); gap:10px; padding:10px 2px; background:#f0f0f8; }
.dev-activity-table { padding:10px; background:#d4d0c8; border:1px solid #808080; box-shadow:inset 1px 1px #fff; }
.dev-activity-table h3 { margin:0 0 9px; color:#000080; font-size:14px; }
.dev-activity-picker, .dev-activity-new, .dev-activity-actions { display:flex; flex-wrap:wrap; gap:5px; margin-top:7px; }
.dev-activity-picker select { flex:1; min-width:150px; min-height:25px; border:2px inset #eee; }
.dev-activity-new input { flex:1; min-width:150px; min-height:21px; border:2px inset #eee; padding:2px 4px; }
.dev-activity-actions { border-top:1px solid #aaa; padding-top:7px; }
.dev-activity-actions .dev-btn { flex:1; min-width:125px; }
@media (max-width:720px) { .dev-activity-tables { grid-template-columns:1fr; } .dev-activity-help { display:none; } }

/* right-side node editor panel */
.dev-de-editor { width:260px; min-width:220px; flex-shrink:0; border-left:1px solid #808080; display:flex; flex-direction:column; overflow:hidden; background:#d4d0c8; }
.dev-de-editor-title { padding:5px 8px; font-weight:700; font-size:12px; background:#000080; color:#fff; }
.dev-de-context-settings { padding:8px; background:#d4d0c8; border:1px solid #808080; box-shadow:inset 1px 1px #fff; }
.dev-de-context-settings strong { display:block; margin-bottom:8px; color:#000080; }
.dev-de-context-settings label { display:flex; flex-direction:column; gap:3px; margin:6px 0; font-size:11px; }
.dev-de-context-settings input { min-height:23px; border:2px inset #eee; padding:2px 4px; box-sizing:border-box; }
.dev-de-ed-sec { padding:4px 6px; }
.dev-de-ed-label { font-size:11px; font-weight:700; color:#333; margin-bottom:3px; }
.dev-de-spk-btn { margin:1px; padding:2px 7px; font-size:11px; min-height:22px; }
.dev-de-spk-btn.active { outline:2px solid currentColor; }
.dev-de-wnum { width:52px; min-height:21px; border:1px inset #eee; padding:1px 3px; font-size:11px; text-align:center; }
.dev-de-opt-row { margin-bottom:6px; padding:4px 6px; background:#e8e8e8; border:1px solid #ccc; }
.dev-de-opt-label { flex:1; min-height:23px; border:2px inset #eee; padding:2px 4px; font-size:12px; min-width:0; }
.dev-de-opt-next { min-height:23px; border:2px inset #eee; padding:2px; font-size:11px; min-width:80px; }

/* ── BGM editor (DevBgmEditorTab) ── */
.dev-bgm-root { height:100%; overflow:auto; padding:0; }
.dev-bgm-root-inner { display:flex; flex-direction:column; gap:0; }
.dev-bgm-toolbar { display:flex; flex-wrap:wrap; gap:4px; padding:6px 8px; border-bottom:1px solid #808080; background:#c8c8c8; }
.dev-bgm-section { padding:8px; border-bottom:1px solid #b0b0b0; }
.dev-bgm-sec-hd { display:flex; align-items:center; gap:8px; margin-bottom:6px; font-weight:700; font-size:13px; }
.dev-bgm-sec-hd .win95-btn { margin-left:auto; }
.dev-bgm-hint { margin:0 0 6px; font-size:11px; color:#555; }
.dev-bgm-table-wrap { overflow-x:auto; }
.dev-bgm-table { width:100%; border-collapse:collapse; font-size:12px; }
.dev-bgm-table th { background:#d0d0d0; border:1px solid #999; padding:3px 6px; text-align:left; font-size:11px; white-space:nowrap; }
.dev-bgm-table td { border:1px solid #ccc; padding:2px 4px; vertical-align:middle; }
.dev-bgm-table tr:nth-child(even) td { background:#f0f0f0; }
.dev-bgm-id { font-size:10px; color:#003399; user-select:all; }
.dev-bgm-name-input, .dev-bgm-note-input { width:100%; min-height:21px; border:1px inset #eee; padding:1px 4px; font-size:12px; box-sizing:border-box; }
.dev-bgm-src-input { width:100%; min-height:21px; border:1px inset #eee; padding:1px 4px; font:11px var(--w95-font); box-sizing:border-box; }
.dev-bgm-ref-cell { text-align:center; white-space:nowrap; }
.dev-bgm-ref-badge { display:inline-block; background:#000080; color:#fff; border-radius:3px; padding:1px 5px; font-size:10px; cursor:default; }
.dev-bgm-ref-none { color:#aaa; font-size:11px; }
.dev-bgm-warn { margin-left:3px; cursor:help; }
.dev-bgm-prev-btn { min-width:26px; padding:1px 4px; }
.dev-bgm-prev-btn.active { background:#000080; color:#fff; }
.dev-bgm-refs-btn, .dev-bgm-del-btn { min-width:26px; padding:1px 4px; }
.dev-bgm-del-btn { color:#900; }
.dev-bgm-search { margin-left:auto; min-height:23px; border:2px inset #eee; padding:2px 6px; font-size:12px; width:160px; }
.dev-bgm-empty { color:#888; font-size:12px; padding:8px; text-align:center; }
.dev-bgm-sel { min-height:23px; border:2px inset #eee; padding:2px; font-size:12px; }
.dev-bgm-bgmid-sel { min-width:120px; }
.dev-bgm-wnum { width:52px; min-height:21px; border:1px inset #eee; padding:1px 3px; font-size:11px; text-align:center; }
.dev-bgm-fb-row { margin-top:6px; font-size:12px; }

/* onShow BGM row inside dialogue node editor */
.dev-de-onshow-bgm { display:flex; align-items:center; gap:4px; margin-top:3px; font-size:11px; }
.dev-de-onshow-bgm select { min-height:21px; border:1px inset #eee; padding:1px 3px; font-size:11px; }
.dev-de-onshow-bgm-indicator { font-size:10px; color:#006600; margin-left:2px; }

/* ── CG editor ── */
.dev-cg-root { display:flex; flex-direction:column; gap:0; }
.dev-cg-toolbar { display:flex; flex-wrap:wrap; gap:4px; padding:6px 0 8px; border-bottom:1px solid #808080; margin-bottom:8px; }
.dev-cg-card { background:#fff; border:1px solid #808080; border-radius:2px; padding:8px; margin-bottom:8px; }
.dev-cg-card-header { display:flex; align-items:center; gap:6px; margin-bottom:6px; }
.dev-cg-card-header b { flex:1; font-size:12px; }
.dev-cg-fields { display:flex; flex-wrap:wrap; gap:8px; align-items:center; margin-bottom:6px; font-size:12px; }
.dev-cg-upload-label { cursor:pointer; color:#000080; text-decoration:underline; font-size:12px; }
.dev-cg-preview { min-height:40px; display:flex; align-items:center; }
.dev-cg-thumb { max-height:120px; max-width:100%; object-fit:contain; border:1px solid #aaa; cursor:zoom-in; }
.dev-cg-no-img { color:#aaa; font-size:11px; font-style:italic; }

/* custom window manager/layout editor */
.dev-cwm-root, .dev-cw-root { display:flex; flex-direction:column; min-height:0; height:100%; gap:6px; }
.dev-cwm-toolbar, .dev-cw-toolbar { display:flex; flex-wrap:wrap; align-items:center; gap:5px; padding-bottom:6px; border-bottom:1px solid #808080; }
.dev-cwm-toolbar span, .dev-cw-file { margin-left:auto; color:#555; font-size:11px; }
.dev-cwm-help, .dev-cw-help, .dev-cw-note { color:#555; font-size:11px; margin:2px 0; }
.dev-cwm-list { display:grid; gap:5px; overflow:auto; }
.dev-cwm-row { display:flex; align-items:center; gap:7px; padding:6px; background:#fff; border:1px solid #808080; cursor:default; }
.dev-cwm-row:hover { background:#d8e8ff; }
.dev-cwm-row strong { min-width:150px; color:#000080; }
.dev-cwm-row small { flex:1; color:#555; font:11px var(--w95-font); }
.dev-cwm-icon { font-size:22px; }
.dev-cwm-empty, .dev-cw-empty { color:#777; padding:14px; }
.dev-cw-main { display:flex; flex:1; min-height:0; overflow:hidden; gap:6px; }
.dev-cw-sidebar, .dev-cw-inspector { width:205px; min-width:180px; overflow:auto; padding:6px; background:#d4d0c8; border:1px solid #808080; box-sizing:border-box; }
.dev-cw-sidebar h4, .dev-cw-inspector h4, .dev-cw-inspector h5 { margin:3px 0 6px; color:#000080; }
.dev-cw-sidebar label, .dev-cw-inspector label { display:flex; flex-direction:column; gap:2px; margin:5px 0; font-size:11px; }
.dev-cw-sidebar input, .dev-cw-inspector input, .dev-cw-inspector select { min-height:22px; box-sizing:border-box; border:2px inset #eee; }
.dev-cw-widget-list { display:grid; gap:3px; }
.dev-cw-widget-row { padding:4px; border:1px solid transparent; cursor:pointer; font-size:11px; }
.dev-cw-widget-row:hover, .dev-cw-widget-row.active { background:#000080; color:#fff; }
.dev-cw-widget-row small { display:block; opacity:.75; }
.dev-cw-canvas-wrap { flex:1; min-width:0; overflow:auto; background:#808080; padding:12px; }
.dev-cw-canvas { position:relative; flex:none; border:2px inset #eee; box-shadow:1px 1px #fff; overflow:hidden; }
.dev-cw-widget { position:absolute; box-sizing:border-box; padding:5px; border:1px solid #777; background:#eee; cursor:move; overflow:hidden; user-select:none; touch-action:none; }
.dev-cw-widget.selected { outline:2px solid #000080; z-index:2; }
.dev-cw-widget > input, .dev-cw-widget > textarea, .dev-cw-widget > select { width:100%; height:100%; box-sizing:border-box; pointer-events:none; }
.dev-cw-widget > button { pointer-events:none; }
.dev-cw-widget-badge { position:absolute; right:2px; bottom:1px; color:#666; font-size:9px; opacity:.7; }
.dev-cw-his-preview { display:flex; gap:6px; height:100%; overflow:visible; }
.dev-cw-his-preview > .dev-cw-widget { position:static; box-sizing:border-box; }
.dev-cw-his-preview > [data-cw-widget="patient-list"] { width:140px; flex:0 0 140px; display:flex; flex-direction:column; gap:4px; padding:6px; background:#fff; }
.dev-cw-his-main { flex:1; min-width:0; display:flex; flex-direction:column; gap:6px; }
.dev-cw-his-main > .dev-cw-widget { position:static; box-sizing:border-box; }
.dev-cw-his-main > [data-cw-widget="medical-incidents"] { padding:0; border:0; background:transparent; }
.dev-cw-his-main > [data-cw-widget="dialogue"],
.dev-cw-his-main > [data-cw-widget="prescription"] { flex:1; min-height:60px; padding:6px; background:#fff; overflow:auto; }
.dev-cw-his-main > [data-cw-widget="diagnosis-panel"] { flex-shrink:0; padding:6px; background:#fff; }
.dev-cw-his-preview .dev-cw-widget[data-cw-widget] .dev-cw-widget { position:static; width:auto; height:auto; margin:4px 0; }
.dev-cw-his-preview .diagnosis-row { display:flex; align-items:center; gap:4px; margin:4px 0; }
.dev-cw-his-preview .diagnosis-row label { width:42px; flex-shrink:0; }
.dev-cw-his-preview .diagnosis-row .dev-cw-widget { flex:1; min-width:0; }
.dev-cw-his-preview .his-prescription-row { display:flex; align-items:center; gap:4px; margin:4px 0; }
.dev-cw-his-preview .his-prescription-row .dev-cw-widget { flex:1; min-width:0; }
.dev-cw-his-preview .his-prescription-row > button { flex:0 0 24px; min-width:24px; padding:1px 4px; }
.dev-cw-event-row { display:flex; align-items:end; gap:3px; }
.dev-cw-event-row label { flex:1; }
.dev-cw-event-row .dev-btn { white-space:nowrap; }
.dev-cw-geometry { display:grid; grid-template-columns:1fr 1fr; gap:3px 6px; }
/* DEV-TOOLS:END */

