/* Debug > Bots: the summary tiles, the filters, the sortable list, the folding tools, and the sheet of one bot (sticky header, scrolling tabs, folding sections). The parts every panel shares are in debug-kit.css. */
.nd-bots { display: flex; flex-direction: column; gap: 8px; max-height: none; overflow: visible; font-size: 12px; min-width: 0; color: var(--dc-text, #26241d); }
.bd-mainview { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.nd-bots .gf-btn, .bd-detail .gf-btn { background: #fff; color: var(--dc-text, #26241d); border: 1px solid var(--dc-line, #d9d3c2); box-shadow: none; border-radius: 4px; font-weight: 600; }
.nd-bots .gf-btn:hover:not(:disabled):not(.on), .bd-detail .gf-btn:hover:not(:disabled):not(.on) { background: var(--dc-soft, #e2eeea); }
.nd-bots .gf-btn.on, .nd-bots .gf-btn[aria-pressed=true], .bd-detail .gf-btn.on { background: var(--dc-accent, #2f6f66); border-color: var(--dc-accent, #2f6f66); color: #fff; }
.nd-bots .gf-btn.small, .bd-detail .gf-btn.small { min-height: 22px; padding: 1px 8px; font-size: 11px; }
.nd-bots details > summary { cursor: pointer; }
.nd-bots details > summary.gf-btn { display: inline-flex; align-items: center; list-style: none; }
.nd-bots details > summary.gf-btn::-webkit-details-marker { display: none; }

/* summary tiles and facet bars */
.nd-bots .bd-summary { display: flex; flex-direction: column; gap: 6px; font-weight: 400; }
.bd-tiles { grid-template-columns: repeat(auto-fit, minmax(72px, 1fr)); gap: 5px; }
.bd-tiles .dc-metric { padding: 5px 7px; }
.bd-tiles .dc-metric strong { font-size: 15px; }
.bd-note { font-size: 11px; margin: 0; }
.bd-facets, .bd-adv, .bd-tool, .bd-cfggroup { padding: 6px 9px; }
.bd-facets > summary, .bd-adv > summary, .bd-tool > summary, .bd-cfggroup > summary { font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--dc-accent, #2f6f66); }
.bd-facetbody { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin-top: 6px; }
.bd-facet h6 { margin: 0 0 3px; font-size: 10px; color: var(--dc-mute, #6c6859); text-transform: uppercase; letter-spacing: .04em; }
.bd-bar-row { all: unset; box-sizing: border-box; display: grid; grid-template-columns: minmax(70px, 38%) 1fr 34px; align-items: center; gap: 6px; width: 100%; padding: 2px 3px; border-radius: 3px; cursor: pointer; font-size: 11px; }
.bd-bar-row:hover { background: var(--dc-soft, #e2eeea); }
.bd-bar-row:focus-visible { outline: 2px solid var(--dc-accent, #2f6f66); }
.bd-bar-row.on { background: var(--dc-soft, #e2eeea); box-shadow: inset 3px 0 var(--dc-accent, #2f6f66); font-weight: 700; }
.bd-bn { text-align: right; font-variant-numeric: tabular-nums; }

/* filters */
.nd-bots .bd-filters { display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 6px; }
.bd-search { width: 100%; box-sizing: border-box; }
.bd-states { gap: 3px; justify-content: flex-start; }
.bd-advgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 10px; margin-top: 6px; }
.bd-advgrid .dc-field { margin: 0; }
.bd-advgrid select, .bd-advgrid input:not([type=checkbox]) { width: 100%; }
.bd-mainchk { grid-column: 1 / -1; }
.bd-active { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.bd-active:empty { display: none; }
.bd-count { font-size: 11px; font-weight: 700; margin-right: 4px; }

/* list: toolbar, table, pager */
.bd-list { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.bd-listtools { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; }
.bd-listtools select { min-width: 0; max-width: 100%; }
.bd-cols { position: relative; }
.bd-colmenu { position: absolute; z-index: 5; top: 100%; left: 0; display: flex; flex-direction: column; gap: 3px; min-width: 170px; max-height: 280px; overflow: auto; padding: 8px; border: 1px solid var(--dc-line, #d9d3c2); border-radius: 6px; background: var(--dc-card, #fffdf8); box-shadow: 0 6px 18px rgba(0, 0, 0, .18); }
.bd-table { table-layout: auto; }
.bd-table td, .bd-table th { vertical-align: middle; }
.bd-table th.num .sortbtn { justify-content: flex-end; }
.bd-table tr.bd-click { cursor: pointer; }
.bd-table tr.bd-click:focus-visible { outline: 2px solid var(--dc-accent, #2f6f66); outline-offset: -2px; }
.bd-table tr.off td { color: var(--dc-mute, #6c6859); }
.bd-table td { padding: 6px 6px; }
.bd-listwrap.dense .bd-table td { padding: 2px 5px; }
.bd-listwrap.dense .bd-table { font-size: 11px; }
.bd-c-name { min-width: 116px; }
.bd-nm { margin-right: 3px; overflow-wrap: anywhere; }
.bd-star { color: #b8860b; margin-right: 3px; }
.bd-cls { display: inline-block; padding: 0 6px; border-radius: 999px; font-size: 10px; font-weight: 700; background: #e7e3d4; color: var(--dc-mute, #6c6859); white-space: nowrap; }
.bd-cls[data-cls=berserker] { background: #f5d9d6; color: #8a2a1f; } .bd-cls[data-cls=assassin] { background: #e0dbef; color: #4a3b7a; }
.bd-cls[data-cls=cleric] { background: #f6ecc8; color: #7a5a00; } .bd-cls[data-cls=wizard] { background: #d9e6f5; color: #1f4d80; }
.bd-lv { font-weight: 800; }
.bd-gold { white-space: nowrap; }
.bd-table .money { gap: 2px; } .bd-table .money .coin { padding: 0 4px; gap: 2px; } .bd-table .money .coin b { font-size: 11px; color: inherit; }
.bd-state { min-width: 80px; font-size: 11px; }
.bd-state.off { font-style: italic; }
.bd-pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; }
.bd-range { font-size: 11px; color: var(--dc-mute, #6c6859); }
.bd-pages { display: flex; flex-wrap: wrap; align-items: center; gap: 3px; }
.bd-pages .gf-btn { min-width: 26px; padding: 1px 5px; }

/* tools: steppers, create form, configuration */
.bd-tools { display: flex; flex-direction: column; gap: 6px; }
.bd-toolbody { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.bd-pop, .bd-create { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.bd-num { display: inline-flex; align-items: center; gap: 5px; }
.bd-num b { display: inline-block; min-width: 40px; text-align: center; font-variant-numeric: tabular-nums; }
.bd-event { margin: 2px 0; font-size: 11px; color: var(--dc-mute, #6c6859); }
.bd-cfg { display: flex; flex-direction: column; gap: 6px; }
.bd-cfgbar { display: flex; align-items: center; gap: 8px; } .bd-cfgbar input { flex: 1; min-width: 0; }
.bd-cfggroups { display: flex; flex-direction: column; gap: 5px; }
.bd-cfggroup > summary .dc-badge { margin-left: 6px; text-transform: none; }
.bd-cfglist { display: flex; flex-direction: column; margin-top: 6px; }
.bd-cfgrow { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 10px; padding: 5px 2px; border-bottom: 1px solid #ece8da; }
.bd-cfgrow[hidden] { display: none; }
.bd-cfglabel { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.bd-cfglabel small { color: var(--dc-mute, #6c6859); font-size: 10px; line-height: 1.3; overflow-wrap: anywhere; }
.bd-modified { font-style: normal; font-size: 10px; color: var(--dc-warn, #a85f00); } .bd-modified:empty { display: none; }
.bd-cfgrow.mod .bd-cfglabel b { color: var(--dc-warn, #a85f00); }
.bd-cfgrow input[type=number] { width: 84px; text-align: right; font-variant-numeric: tabular-nums; }

/* the sheet of a bot: the header stays on top while the page scrolls */
.bd-detail { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.bd-sticky { position: sticky; top: 0; z-index: 4; display: flex; flex-direction: column; gap: 6px; padding: 4px 0 0; background: var(--dc-bg, #f5f3ec); border-bottom: 1px solid var(--dc-line, #d9d3c2); }
.debug-console .bd-sticky { top: -10px; margin: -10px -12px 0; padding: 8px 12px 0; }
.bd-bar2 { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.bd-nav { display: inline-flex; align-items: center; gap: 4px; } .bd-pos { font-size: 11px; font-variant-numeric: tabular-nums; color: var(--dc-mute, #6c6859); }
.bd-spacer { flex: 1; }
.bd-top { display: flex; flex-direction: column; gap: 2px; }
.bd-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; }
.bd-name { font-size: 15px; overflow-wrap: anywhere; } .bd-lvl { font-weight: 700; font-size: 12px; }
.bd-where { font-size: 11px; color: var(--dc-mute, #6c6859); overflow-wrap: anywhere; }
.bd-pill { padding: 0 8px; border-radius: 10px; font-size: 10px; font-weight: 700; background: #e7e3d4; color: var(--dc-mute, #6c6859); }
.bd-pill.online { background: #dcefe0; color: var(--dc-good, #2b7a3d); } .bd-pill.offline { background: #e7e3d4; } .bd-pill.connecting, .bd-pill.changingMap { background: #f6e6c8; color: var(--dc-warn, #a85f00); }
.bd-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.bd-acts select { min-height: 22px; font-size: 11px; max-width: 100%; }
.bd-more { position: relative; } .bd-more[open] { flex-basis: 100%; }
.bd-more .bd-acts { margin-top: 4px; }
.bd-tabs { display: flex; flex-wrap: nowrap; overflow-x: auto; gap: 2px; margin: 0; scrollbar-width: thin; }
.bd-tabs .gfw-tab { flex: none; padding: 6px 9px; font-size: 11px; font-weight: 700; border: 0; border-bottom: 3px solid transparent; border-radius: 0; background: transparent; color: var(--dc-mute, #6c6859); white-space: nowrap; box-shadow: none; }
.bd-tabs .gfw-tab:hover:not(.on) { background: transparent; color: var(--dc-text, #26241d); }
.bd-tabs .gfw-tab.on { color: var(--dc-accent, #2f6f66); border-bottom-color: var(--dc-accent, #2f6f66); background: transparent; box-shadow: none; }
.bd-page { display: flex; flex-direction: column; gap: 8px; min-width: 0; }

/* sections: folding cards with aligned label / value lines */
.bd-detail details.bd-sec { padding: 0; gap: 0; display: block; background: var(--dc-card, #fffdf8); box-shadow: none; border: 1px solid var(--dc-line, #d9d3c2); border-radius: 6px; }
.bd-detail details.bd-sec > summary { padding: 7px 10px; list-style: none; }
.bd-detail details.bd-sec > summary::-webkit-details-marker { display: none; }
.bd-detail details.bd-sec > summary h5 { display: inline; margin: 0; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--dc-accent, #2f6f66); }
.bd-detail details.bd-sec > summary h5::before { content: '▸'; display: inline-block; width: 12px; transition: transform .1s; }
.bd-detail details.bd-sec[open] > summary h5::before { transform: rotate(90deg); }
.bd-secbody { display: flex; flex-direction: column; gap: 3px; padding: 0 10px 9px; min-width: 0; }
.bd-secbody h6 { margin: 8px 0 2px; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; color: var(--dc-mute, #6c6859); }
.bd-kv { display: grid; grid-template-columns: minmax(84px, 40%) minmax(0, 1fr); gap: 2px 10px; align-items: baseline; padding: 2px 0; border-bottom: 1px dotted #e4dfcf; font-size: 12px; }
.bd-kv:last-child { border-bottom: 0; }
.bd-k { color: var(--dc-mute, #6c6859); overflow-wrap: anywhere; } .bd-v { overflow-wrap: anywhere; min-width: 0; }
.bd-kv.num .bd-v { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.bd-hint { display: block; font-size: 10px; line-height: 1.3; color: var(--dc-mute, #6c6859); opacity: .85; }
.bd-detail .bd-bar { height: 16px; background: #e7e3d4; border-radius: 8px; } .bd-detail .bd-bar i { background: var(--dc-accent, #2f6f66); opacity: .55; }
.bd-detail .bd-bar span { color: var(--dc-text, #26241d); }
.bd-detail .bd-gear, .bd-detail .bd-fortrow { grid-template-columns: minmax(70px, 32%) minmax(0, 1fr) auto; gap: 4px 8px; font-size: 11px; overflow-wrap: anywhere; }
.bd-detail .bd-gear em { color: var(--dc-warn, #a85f00); }
.bd-detail .bd-trade { grid-template-columns: 18px minmax(0, 1fr) auto; overflow-wrap: anywhere; }
.bd-detail .bd-set { background: #faf8f1; box-shadow: inset 0 0 0 1px var(--dc-line, #d9d3c2); } .bd-detail .bd-set.on { box-shadow: inset 0 0 0 2px var(--dc-accent, #2f6f66); background: var(--dc-soft, #e2eeea); }
.bd-detail .bd-equip { max-width: 100%; overflow-x: auto; justify-content: flex-start; }
@media (max-width: 700px) { .bd-advgrid { grid-template-columns: minmax(0, 1fr); } .bd-kv { grid-template-columns: 90px minmax(0, 1fr); } }
