/* ==========================================================================
   D – Dashboard (roots: .picker, .shell, .ops). Cherry Chrome, the calm tool.
   Black, dense, no curtain, no lacquer, no idle animation. Red only as switch
   tracks, the one Save button, the rail marker and the attention slab.
   ========================================================================== */

/* ---------- shared header (picker + operator) ---------- */
:is(.picker, .ops) .dtop { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 16px; height: var(--nav-h); }
:is(.picker, .ops) .dtop-end { display: flex; align-items: center; gap: 18px; min-width: 0; }
:is(.picker, .ops) .dtop-link { display: inline-flex; align-items: center; height: 40px; padding: 0 14px; border-radius: var(--r-pill); font-size: 15px; font-weight: 500; font-stretch: var(--w-ui); color: var(--steel); text-decoration: none; transition: color var(--t-fast), background-color var(--t-fast); }
:is(.picker, .ops) .dtop-link:hover { color: var(--platinum); background: rgba(246, 242, 239, .06); }
:is(.picker, .ops) .dtop-user { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--fs-small); color: var(--steel); }
:is(.picker, .shell, .ops) h1 { font-size: clamp(38px, 5.6vw, 72px); }

/* ---------- server picker ---------- */
.picker { position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden; padding: 0 var(--gutter) 96px; background: radial-gradient(46% 60% at 100% 52%, rgba(160, 10, 32, .34) 0%, rgba(90, 6, 18, .12) 50%, transparent 76%), var(--pitch); }
.picker-main { position: relative; z-index: 2; max-width: 760px; padding-top: clamp(40px, 9vh, 104px); }
.picker-lede { max-width: 34em; margin-top: 16px; font-size: var(--fs-lede); line-height: 1.5; color: var(--steel); }
.picker .search { margin-top: 32px; }
.picker .prows { margin-top: 36px; }
.picker .prow:first-child { border-top: 1px solid var(--line); }
.picker .prow { position: relative; isolation: isolate; display: grid; grid-template-columns: 56px minmax(0, 1fr) auto auto; align-items: center; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.picker .prow::before, .shell .modrow::before { content: ""; position: absolute; z-index: -1; inset: 0 -14px; border-radius: 4px; background: var(--oxblood); opacity: 0; transition: opacity var(--t-fast); }
.picker .prow:hover::before, .shell .modrow:hover::before { opacity: 1; }
.picker-more { margin-top: 18px; font-size: var(--fs-small); color: var(--steel); }
.picker .prow:focus-visible { outline-offset: -2px; border-radius: 4px; }
.picker .prow .gicon { width: 56px; height: 56px; border-radius: 16px; font-size: 22px; }
.picker .prow-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-stretch: var(--w-display); font-weight: 800; font-size: 24px; letter-spacing: -.03em; line-height: 1.1; color: var(--platinum); }
.picker .prow .badge .dot { width: 7px; height: 7px; }
.picker .prow .btn { pointer-events: none; }
.picker .prow:hover .btn:not(.solid) { border-color: var(--platinum); }
.picker-empty { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line-strong); }
.picker-empty h2 { margin-bottom: 20px; }
/* the one red object: the V on its cherry disc, cut by the right edge */
.picker-v { --v: min(60vw, 860px); position: absolute; z-index: 1; top: 52%; right: calc(var(--v) * -.5); width: var(--v); height: var(--v); transform: translateY(-46%); pointer-events: none; }
.picker-disc { position: absolute; inset: 14%; border-radius: 50%; background: radial-gradient(circle at 36% 30%, #ff3a3f 0%, var(--cherry) 38%, #b20c22 100%); box-shadow: 0 0 140px 10px rgba(229, 18, 46, .24); }
.picker-v img { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-8deg); }

/* ---------- shell: rail + main column ---------- */
.shell { display: grid; grid-template-columns: var(--rail) minmax(0, 1fr); min-height: 100vh; font-size: 15.5px; }
.shell .shell-bar { display: none; }
.shell .rail { position: sticky; top: 0; display: flex; flex-direction: column; height: 100vh; height: 100dvh; overflow-y: auto; padding: 18px 12px; background: var(--pitch); border-right: 1px solid var(--line); scrollbar-width: thin; }
.shell .rail-head { position: sticky; top: -18px; z-index: 1; display: flex; align-items: center; gap: 8px; margin: -18px 0 10px; padding: 22px 4px 16px; background: var(--pitch); border-bottom: 1px solid var(--line); }
.shell .rail-guild { display: flex; flex: 1; align-items: center; gap: 12px; min-width: 0; margin: -6px; padding: 6px; border-radius: 12px; text-decoration: none; transition: background-color var(--t-fast); }
.shell .rail-guild:hover { background: var(--oxblood); }
.shell .rail-guild .gicon, .shell .shell-guild .gicon { width: 36px; height: 36px; border-radius: 10px; font-size: 15px; }
.shell .rail-guild b, .shell .shell-guild b { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-stretch: var(--w-display); font-weight: 800; font-size: 17px; letter-spacing: -.03em; color: var(--platinum); }
.shell .rail-close { display: none; }
.shell .rail-nav { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1px; }
.shell .rlink { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 12px 0 14px; border-radius: 0 10px 10px 0; font-size: 15px; font-weight: 600; font-stretch: var(--w-ui); color: var(--steel); text-decoration: none; transition: color var(--t-fast), background-color var(--t-fast); }
.shell .rlink .ico { width: 18px; height: 18px; }
.shell .rlink-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell .rlink:hover { color: var(--platinum); background: var(--oxblood); }
.shell .rlink:focus-visible { outline-offset: -2px; }
.shell .rlink[aria-current] { color: var(--platinum); box-shadow: inset 2px 0 0 var(--cherry); }
.shell .rlink .state { flex: none; width: 8px; height: 8px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--smoke); }
.shell .rlink .state.on { background: var(--cherry); box-shadow: none; }
.shell .rail-sep { height: 1px; margin: 10px 12px; background: var(--line); }
.shell .rail-end { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding: 18px 4px 2px 14px; }
.shell .rail-nav + .rail-end { margin-top: 18px; border-top: 1px solid var(--line); }
.shell .rail-small { font-size: 14px; font-weight: 600; color: var(--steel); text-decoration: none; }
.shell .rail-small:hover { color: var(--platinum); }

.shell .main { width: 100%; max-width: 1040px; min-width: 0; padding: 40px clamp(20px, 4vw, 56px) 140px; }

/* ---------- page head with the big switch ---------- */
:is(.shell, .ops) .mhead { position: relative; align-items: flex-end; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
:is(.shell, .ops) .mhead-text { flex: 1 1 420px; min-width: 0; }
:is(.shell, .ops) .mhead h1 { overflow-wrap: anywhere; }
:is(.shell, .ops) .mhead p { max-width: 40em; font-size: 16.5px; }
.shell .mhead-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.shell .onoff { padding-bottom: 4px; }
.shell .onoff-word { min-width: 2.3ch; font-stretch: var(--w-display); font-weight: 900; font-size: 28px; letter-spacing: -.03em; line-height: 1; text-align: right; color: var(--platinum); }
.shell .mhead::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--cherry); opacity: 0; pointer-events: none; }
.shell .mhead.flash::after { animation: dash-flash 600ms var(--ease) var(--flash-at, 0ms) both; }
@keyframes dash-flash { 0% { opacity: 0; } 22% { opacity: 1; } 100% { opacity: 0; } }

/* ---------- settings form ---------- */
.shell .form { max-width: 820px; }
.shell .fgroup:not(.rule) { margin-top: 8px; }
.shell .fgroup.rule { margin-top: 34px; padding-top: 18px; }
.shell .fgroup h2 { font-size: 24px; }
.shell .field { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 8px 32px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.shell .field:last-child { border-bottom: 0; }
.shell .mhead + .form > .fgroup.rule:first-child { margin-top: 16px; border-top: 0; }
.shell .field.wide { grid-template-columns: minmax(0, 1fr); }
.shell .field-l { min-width: 0; padding-top: 11px; }
.shell .field.is-bool .field-l { padding-top: 3px; }
.shell .field.wide .field-l { padding-top: 0; }
.shell .field .lbl { display: block; font-size: 15.5px; font-weight: 700; line-height: 1.35; color: var(--platinum); }
.shell .field .help { max-width: 36em; margin-top: 4px; line-height: 1.45; }
.shell .field-c { min-width: 0; }
.shell .field .err { margin-top: 8px; }
.shell .stack { display: grid; gap: 8px; }
.shell .presets { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 4px; }
.shell .presets .filters button { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.shell .num-in, .shell .dur-in { max-width: 200px; }

/* multi-select: chips + "Add role" with a searchable menu */
.shell .multi { position: relative; }
.shell .chips { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-height: var(--h-control); }
.shell .chip { max-width: 100%; min-width: 0; }
.shell .chip-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell .chip button { position: relative; flex: none; font-size: 16px; }
.shell .chip button::after { content: ""; position: absolute; inset: -9px; }
.shell .multi-none { margin-right: 4px; font-size: var(--fs-small); color: var(--smoke); }
.shell .pick { position: absolute; z-index: 45; top: calc(100% + 8px); left: 0; width: min(380px, 100%); padding: 8px; border-radius: 18px; background: var(--glass); box-shadow: var(--sh-pop); }
.shell .pick .search { max-width: none; min-height: 40px; }
.shell .pick-list { min-width: 0; max-height: 300px; overflow-y: auto; margin-top: 6px; padding: 0; border-radius: 0; box-shadow: none; background: none; scrollbar-width: thin; }
.shell .pick-list > button { min-height: 40px; }
.shell .pick-list > button:focus-visible { outline-offset: -2px; }
.shell .pick-l { display: flex; align-items: center; gap: 10px; min-width: 0; }
.shell .pick-l > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell .pick-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--steel); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); }
.shell .pick-on { flex: none; font-size: 12.5px; font-weight: 700; }
.shell .pick-group { padding: 10px 12px 4px; font-size: 12.5px; font-weight: 600; color: var(--smoke); }

/* colour: picker + hex + round swatches */
.shell .colorrow { display: flex; align-items: center; gap: 10px; }
.shell .colorrow .input.short { width: 140px; }
.shell .swatches { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.shell .swatch { position: relative; flex: none; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22), 0 1px 3px rgba(0, 0, 0, .6); cursor: pointer; transition: transform var(--t-press) var(--ease), box-shadow var(--t-fast); }
.shell .swatch::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; }
.shell .swatch:hover { transform: translateY(-2px); }
.shell .swatch:active { transform: scale(.94); }
.shell .swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--pitch), 0 0 0 4px var(--platinum); }

/* collections: hairline rows, inline controls, a knob to remove */
.shell .coll-head, .shell .coll-row { display: grid; grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr)) 36px; gap: 12px; align-items: center; }
.shell .coll-head { padding: 0 0 8px; font-size: var(--fs-label); font-weight: 600; color: var(--smoke); }
.shell .coll-row { padding: 10px 0; border-top: 1px solid var(--line); }
.shell .coll-rows { border-bottom: 1px solid var(--line); }
.shell .coll-cell { min-width: 0; }
.shell .coll-cl { display: none; }
.shell .coll-empty { padding: 4px 0 0; }
.shell .coll-add { display: flex; align-items: center; gap: 14px; padding-top: 14px; }
.shell .coll-count { font-size: 16px; color: var(--smoke); }
.shell .coll-items { border-bottom: 1px solid var(--line); }
.shell .citem { border-top: 1px solid var(--line); }
.shell .citem > summary { display: flex; align-items: center; gap: 14px; min-height: 58px; margin: 0 -10px; padding: 8px 10px; list-style: none; cursor: pointer; font-weight: 700; color: var(--platinum); transition: background-color var(--t-fast); }
.shell .citem > summary::-webkit-details-marker { display: none; }
.shell .citem > summary:hover { background: var(--oxblood); }
.shell .citem > summary:focus-visible { outline-offset: -2px; }
.shell .citem-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell .citem-body { padding: 0 0 14px 38px; }
.shell .citem-body .field { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); }
.shell .citem-body .field:last-child { border-bottom: 0; }
/* the plus that becomes a minus (collections and builder groups) */
.shell :is(.citem-mark, .bgroup-mark) { position: relative; flex: none; width: 24px; height: 24px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--line-strong); }
.shell :is(.citem-mark, .bgroup-mark)::before, .shell :is(.citem-mark, .bgroup-mark)::after { content: ""; position: absolute; top: 11px; left: 7px; width: 10px; height: 2px; border-radius: 2px; background: var(--platinum); transition: transform var(--t-fast) var(--ease); }
.shell :is(.citem-mark, .bgroup-mark)::after { transform: rotate(90deg); }
.shell details[open] > summary :is(.citem-mark, .bgroup-mark)::after { transform: rotate(0deg); }

.shell .mod-acts { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 28px; }
.shell .cmds { margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--line); }
.shell .cmds h3 { margin-bottom: 10px; }
.shell .cmds p { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.shell .cmds code { font-size: 15px; color: var(--steel); white-space: nowrap; }

/* save bar: a chrome pill that slides up */
.shell .savebar { --focus: var(--on-chrome); position: fixed; z-index: var(--z-sticky); left: calc(var(--rail) + 24px); right: 24px; bottom: 20px; display: flex; align-items: center; gap: 10px; max-width: 820px; padding: 7px 7px 7px 24px; border-radius: var(--r-pill); background: var(--chrome-soft); color: var(--on-chrome); font-weight: 700; font-stretch: var(--w-ui); box-shadow: 0 26px 50px -18px #000, inset 0 0 0 1px rgba(255, 255, 255, .7); transform: translateY(calc(100% + 40px)); visibility: hidden; transition: transform var(--t-med) var(--ease), visibility 0s linear var(--t-med); }
.shell .savebar.show { transform: none; visibility: visible; transition: transform var(--t-med) var(--ease), visibility 0s; }
.shell .savebar > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell .savebar .btn:not(.solid) { border-color: rgba(18, 6, 8, .42); color: var(--on-chrome); }
.shell .savebar .btn:not(.solid):hover { border-color: var(--on-chrome); background: rgba(18, 6, 8, .06); }

/* ---------- lists and blocks (overview, stats, operator) ---------- */
:is(.shell, .ops) .figures { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
:is(.shell, .ops) .figures b { font-size: clamp(40px, 4.4vw, 60px); }
.shell .attention + .figures { margin-top: 8px; }
:is(.shell, .ops) .figures .trend { display: block; margin-top: 4px; font-size: 13px; font-style: normal; font-weight: 600; color: var(--platinum); }
:is(.shell, .ops) .figures .trend.down { color: var(--flare); }
:is(.shell, .ops) .rule h2, :is(.shell, .ops) .blockhead h2 { font-size: 24px; }
:is(.shell, .ops) .rule > h2 { margin-bottom: 12px; }
:is(.shell, .ops) .blockhead { display: flex; align-items: baseline; gap: 12px; }
:is(.shell, .ops) .blockhead-n { font-size: 22px; color: var(--smoke); }
:is(.shell, .ops) .drows { border-top: 1px solid var(--line); }
:is(.shell, .ops) .drow { display: flex; align-items: baseline; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
:is(.shell, .ops) .drow-n { flex: none; width: 30px; font-size: 16px; color: var(--smoke); }
:is(.shell, .ops) .drow-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--body); }
:is(.shell, .ops) .drow-t b { color: var(--platinum); }
:is(.shell, .ops) .drow-r { flex: none; font-size: 13.5px; color: var(--smoke); white-space: nowrap; text-align: right; }
:is(.shell, .ops) .drow-r.num, :is(.shell, .ops) .drow-r .num { font-size: 17px; color: var(--platinum); }
:is(.shell, .ops) .drow .av { flex: none; align-self: center; width: 26px; height: 26px; border-radius: 50%; object-fit: cover; background: var(--oxblood); }
:is(.shell, .ops) .side-note { max-width: 34em; font-size: var(--fs-small); color: var(--steel); }
:is(.shell, .ops) .side-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
:is(.shell, .ops) .ov-cols { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; align-items: start; margin-top: 40px; }
:is(.shell, .ops) .cols2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; align-items: start; margin-top: 48px; }
:is(.shell, .ops) .cols3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; align-items: start; margin-top: 48px; }

/* overview */
.shell .attention { margin-top: 32px; padding: clamp(22px, 3vw, 34px); }
.shell .attention h2 { margin-bottom: 18px; font-size: clamp(24px, 2.6vw, 34px); }
.shell .attention-list { padding: 4px 20px; }
.shell .attention-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); }
.shell .attention-row:first-child { border-top: 0; }
.shell .attention-row > .ico { width: 20px; height: 20px; color: var(--flare); }
.shell .attention-t { flex: 1; min-width: 0; color: var(--steel); }
.shell .attention-t b { margin-right: 8px; color: var(--platinum); }
.shell .toolrow { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin: 16px 0 14px; }
.shell .toolrow .search { flex: 1 1 220px; }
.shell .modrow:first-child { border-top: 1px solid var(--line); }
.shell .modrow { position: relative; isolation: isolate; display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.shell .modrow .ico-tile .ico { width: 18px; height: 18px; color: var(--steel); }
.shell .modrow-t { display: block; min-width: 0; text-decoration: none; }
.shell .modrow-t:focus-visible { outline-offset: 2px; border-radius: 4px; }
.shell .modrow-t b { display: block; font-size: 15.5px; color: var(--platinum); }
.shell .modrow-t span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; color: var(--steel); }
.shell .modrow-t:hover b { text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.shell .ov-side { display: grid; grid-template-columns: minmax(0, 1fr); gap: 44px; }

/* statistics */
.shell .rangebar { margin-top: 20px; }
.shell .rangebar + .figures { border-top: 0; }
:is(.shell, .ops) .figures:has(+ .rule, + .cols2, + .ov-cols) { border-bottom: 0; }
:is(.shell, .ops) .cols3 h2 { font-size: 20px; }
.shell a.tab { display: inline-flex; align-items: center; text-decoration: none; }
.shell .dnote { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--body); }
:is(.shell, .ops) .cblock > h2 { margin-bottom: 22px; }
.shell .cblock { margin-top: 40px; }
:is(.shell, .ops) .chart { min-width: 0; }
:is(.shell, .ops) .cplot { position: relative; }
:is(.shell, .ops) .cgrid { position: absolute; inset: 0 0 0 0; display: flex; flex-direction: column; justify-content: space-between; pointer-events: none; }
:is(.shell, .ops) .cgrid-l { position: relative; height: 0; border-top: 1px solid var(--line); }
:is(.shell, .ops) .cgrid-l:last-child { border-top-color: var(--line-strong); }
:is(.shell, .ops) .cgrid-l em { position: absolute; right: 0; top: -9px; font-style: normal; font-stretch: var(--w-num); font-weight: 700; font-size: 12.5px; line-height: 18px; font-variant-numeric: tabular-nums; color: var(--smoke); }
:is(.shell, .ops) .cbars { position: relative; display: flex; align-items: flex-end; gap: 4px; height: 140px; margin-right: 52px; }
:is(.shell, .ops) .cbars.tall { height: 220px; }
:is(.shell, .ops) .cbars.dense { gap: 2px; }
:is(.shell, .ops) .ccol { display: flex; flex: 1; align-items: flex-end; justify-content: center; height: 100%; min-width: 0; border-radius: 4px 4px 0 0; cursor: default; transition: background-color var(--t-fast); }
:is(.shell, .ops) .ccol i { display: block; width: 100%; max-width: 12px; height: var(--v, 0%); border-radius: 3px 3px 0 0; background: var(--cherry); transition: background-color var(--t-fast); }
:is(.shell, .ops) .ccol.on { background: rgba(246, 242, 239, .05); }
:is(.shell, .ops) .ccol.on i { background: var(--flare); }
:is(.shell, .ops) .ccol:focus-visible { outline-offset: 1px; }
:is(.shell, .ops) .ctip { position: absolute; z-index: 3; top: 0; width: 132px; padding: 8px 12px; border-radius: 12px; background: var(--glass); box-shadow: var(--sh-pop); font-size: 13.5px; line-height: 1.3; color: var(--body); pointer-events: none; }
:is(.shell, .ops) .ctip b { font-stretch: var(--w-num); font-weight: 800; font-size: 20px; font-variant-numeric: tabular-nums; color: var(--platinum); }
:is(.shell, .ops) .ctip small { display: block; margin-top: 2px; font-size: 12.5px; color: var(--smoke); }
:is(.shell, .ops) .cempty { position: absolute; left: 0; bottom: 18px; font-size: var(--fs-small); color: var(--smoke); }
:is(.shell, .ops) .chart .axis { margin-right: 52px; font-size: 12.5px; }
:is(.shell, .ops) .chart .axis .num { font-weight: 700; font-size: 13.5px; }
.shell .tableview { margin-top: 48px; }
.shell .tableview > summary { list-style: none; }
.shell .tableview > summary::-webkit-details-marker { display: none; }
.shell .tableview[open] > summary { border-color: var(--platinum); }
.shell .tableview .data-wrap { max-width: 640px; margin-top: 18px; }

/* dialog */
:is(.shell, .ops, .picker) .dask h2 { padding-right: 48px; font-size: clamp(22px, 2.4vw, 28px); }
:is(.shell, .ops, .picker) .dask p { margin-top: 12px; color: var(--steel); }
:is(.shell, .ops, .picker) .dask-acts { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; margin-top: 28px; }

/* ---------- operator ---------- */
.ops { min-height: 100vh; padding: 0 var(--gutter) 96px; font-size: 15.5px; }
.ops .ops-main { max-width: 1240px; padding-top: 32px; }
.ops .ops-block { margin-top: 56px; }
.ops .ops-block > .search { margin: 16px 0 12px; }
.ops .srvtable td { padding-block: 10px; }
.ops .srv { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ops .srv .gicon { width: 36px; height: 36px; border-radius: 10px; font-size: 15px; }
.ops .srv-t { min-width: 0; }
.ops .srv-t b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--platinum); }
.ops .srv-t small { display: block; font-size: 12.5px; font-stretch: var(--w-num); font-weight: 600; letter-spacing: .02em; color: var(--smoke); }
.ops .srvtable :is(th, td).acts { width: 1%; padding-right: 0; padding-left: 28px; text-align: right; }
.ops .figures b { font-size: clamp(36px, 3.6vw, 52px); }
.ops .ops-side { display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px; }
.ops .srv-acts { display: inline-flex; gap: 8px; }
.ops .statusbox { display: grid; gap: 10px; max-width: 640px; margin-top: 18px; }
.ops .statusbox .label { margin-bottom: 0; }
.ops .statusrow { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; color: var(--steel); }
.ops .statusrow .btn { margin-left: auto; }
.ops .blockrow { display: flex; gap: 10px; margin: 16px 0; }
.ops .blockrow .input { flex: 1; }
.ops .errrow .drow-r { display: grid; justify-items: end; }
.ops .drow .tag { align-self: center; }

/* ---------- embed builder ---------- */
.shell .b-templates { margin-top: 24px; }
.shell .b-start { margin: 0 0 8px; }
.shell .builder { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: start; margin-top: 16px; }
.shell .b-view { display: none; }
.shell .b-form { min-width: 0; }
.shell .b-form .field.wide { gap: 8px; padding: 14px 0; border-bottom: 0; }
.shell .b-form > .field.wide:first-child { padding-top: 4px; }
.shell .b-embeds { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 22px 0 12px; }
.shell .b-embeds h3 { font-size: 19px; }
.shell .bgroup { border-top: 1px solid var(--line); }
.shell .bgroup:last-child { border-bottom: 1px solid var(--line); }
.shell .b-remove + .bgroup, .shell .field + .bgroup { margin-top: 8px; }
.shell .bgroup > summary { display: flex; align-items: center; gap: 12px; min-height: 58px; margin: 0 -10px; padding: 8px 10px; list-style: none; cursor: pointer; transition: background-color var(--t-fast); }
.shell .bgroup > summary::-webkit-details-marker { display: none; }
.shell .bgroup > summary:hover { background: var(--oxblood); }
.shell .bgroup > summary:focus-visible { outline-offset: -2px; }
.shell .bgroup-t { font-stretch: var(--w-display); font-weight: 800; font-size: 17px; letter-spacing: -.02em; color: var(--platinum); }
.shell .bgroup-m { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: right; font-size: 14px; color: var(--smoke); }
.shell .bgroup-body { padding: 0 0 18px; }
.shell .bgroup-body > .field.wide:first-child { padding-top: 2px; }
.shell .bgroup-body > .check { margin-top: 6px; }
.shell .frow { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.shell .frow:first-child { padding-top: 2px; }
.shell .pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.shell .b-remove { padding: 18px 0 8px; }
.shell .b-side { position: sticky; top: 24px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; min-width: 0; }
.shell .b-screen { padding: 8px 10px 10px; border-radius: var(--r-panel); box-shadow: var(--sh-object); }
.shell .b-screen-h { display: flex; align-items: center; justify-content: space-between; padding: 4px 8px 10px; }
.shell .b-led { width: 8px; height: 8px; border-radius: 50%; background: var(--platinum); box-shadow: 0 0 0 3px rgba(246, 242, 239, .14); }
.shell .b-send, .shell .b-save { display: flex; flex-wrap: wrap; gap: 8px; }
.shell .b-send select { flex: 1 1 180px; width: auto; }
.shell .b-emoji { padding-top: 14px; border-top: 1px solid var(--line); }
.shell .palette { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 2px; margin: 10px 0 8px; }
.shell .emo-btn { display: grid; place-items: center; height: 40px; padding: 0; border: 0; border-radius: 10px; background: none; cursor: pointer; transition: background-color var(--t-fast), transform var(--t-press) var(--ease); }
.shell .emo-btn img { width: 22px; height: 22px; opacity: .82; }
.shell .emo-btn:hover { background: var(--oxblood); }
.shell .emo-btn:hover img { opacity: 1; }
.shell .emo-btn:active { transform: scale(.94); }
.shell .b-emoji .help { max-width: 40em; }

/* The Discord message keeps Discord's own look: its greys, its blurple, its type. None of the site tokens. */
.shell .dc { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 0 16px; min-height: 150px; padding: 16px 16px 18px; border-radius: 10px; background: #313338; font: 400 16px/1.375 "gg sans", "Helvetica Neue", Helvetica, Arial, sans-serif; font-stretch: normal; letter-spacing: 0; color: #dbdee1; overflow-wrap: anywhere; }
.shell .dc .av { width: 40px; height: 40px; margin-top: 2px; border-radius: 50%; object-fit: cover; background: #1e1f22; }
.shell .dc .msg { min-width: 0; }
.shell .dc .who { display: flex; align-items: center; gap: 6px; line-height: 22px; }
.shell .dc .who b { font-weight: 500; color: #f2f3f5; }
.shell .dc .who i { height: 15px; padding: 0 4px; border-radius: 3px; background: #5865f2; font: 600 10px/15px "gg sans", "Helvetica Neue", Arial, sans-serif; font-style: normal; color: #fff; }
.shell .dc .who time { margin-left: 2px; font-size: 12px; color: #949ba4; }
.shell .dc .hint { color: #949ba4; }
.shell .dc b { font-weight: 600; }
.shell .dc small { font-size: 13px; color: #949ba4; }
.shell .dc .emo { width: 1.375em; height: 1.375em; vertical-align: -.3em; }
.shell .dc .embed { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 16px; max-width: 516px; margin-top: 6px; padding: 8px 16px 16px 12px; border-left: 4px solid #1e1f22; border-radius: 4px; background: #2b2d31; }
.shell .dc .embed > * { grid-column: 1; }
.shell .dc .embed .thumb { grid-column: 2; grid-row: 1 / span 4; width: 80px; height: 80px; margin-top: 8px; border-radius: 4px; object-fit: cover; }
.shell .dc .author { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 14px; font-weight: 600; color: #f2f3f5; }
.shell .dc .author img, .shell .dc .foot img { width: 24px; height: 24px; border-radius: 50%; }
.shell .dc .title { margin-top: 8px; font-size: 16px; font-weight: 600; color: #f2f3f5; }
.shell .dc .title a { color: #00a8fc; text-decoration: none; }
.shell .dc .desc { margin-top: 8px; font-size: 14px; }
.shell .dc .fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 8px; font-size: 14px; }
.shell .dc .fields div { grid-column: span 3; }
.shell .dc .fields div.in { grid-column: span 1; }
.shell .dc .fields b { display: block; margin-bottom: 2px; color: #f2f3f5; }
.shell .dc .embed .image { grid-column: 1 / -1; max-width: 100%; margin-top: 16px; border-radius: 4px; }
.shell .dc .embed .foot { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 12px; color: #b5bac1; }
.shell .dc .btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.shell .dc .btns span { padding: 2px 16px; min-height: 32px; display: inline-flex; align-items: center; border-radius: 8px; background: #4e5058; font-size: 14px; font-weight: 500; color: #fff; }
.shell .dc code { padding: 0 3px; border-radius: 4px; background: #1e1f22; font: 13.5px/1.3 Consolas, "Andale Mono WT", "Andale Mono", "Lucida Console", monospace; font-stretch: normal; color: #dbdee1; }
.shell .dc .mention { padding: 0 2px; border-radius: 3px; background: rgba(88, 101, 242, .3); font-weight: 500; color: #c9cdfb; }
.shell .dc a { color: #00a8fc; }

/* ---------- ≤1080: no picture on the picker ---------- */
@media (max-width: 1080px) {
  .picker-v { display: none; }
  .picker { background: var(--pitch); }
  :is(.shell, .ops) .cols3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shell .builder { gap: 28px; }
}

/* ---------- ≤900: the rail becomes a sheet behind a menu knob ---------- */
@media (max-width: 900px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .shell .shell-bar { position: sticky; top: 0; z-index: var(--z-sticky); display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 16px; background: var(--pitch); border-bottom: 1px solid var(--line); }
  .shell .shell-menu { align-content: center; gap: 4px; }
  .shell .shell-menu span { display: block; width: 16px; height: 2px; border-radius: 2px; background: var(--on-chrome); }
  .shell .shell-guild { display: flex; align-items: center; gap: 10px; min-width: 0; text-decoration: none; }
  .shell .shell-guild .gicon { width: 32px; height: 32px; }
  .shell .rail { position: fixed; inset: 0; z-index: var(--z-scrim); width: auto; height: auto; padding: 0 16px 28px; border-right: 0; transform: translateY(-100%); visibility: hidden; transition: transform var(--t-med) var(--ease), visibility 0s linear var(--t-med); }
  .shell.sheet-open .rail { transform: none; visibility: visible; transition: transform var(--t-med) var(--ease), visibility 0s; }
  .shell .rail-head { position: sticky; top: 0; z-index: 1; height: 64px; margin: 0 0 10px; padding: 0; background: var(--pitch); border-bottom: 1px solid var(--line); }
  .shell .rail-guild { margin: 0; }
  .shell .rail-close { display: inline-grid; }
  .shell .rlink { height: 48px; font-size: 16.5px; }
  .shell .rlink .ico { width: 20px; height: 20px; }
  .shell .main { padding: 28px 16px 140px; }
  .shell .field, .shell .citem-body .field { grid-template-columns: minmax(0, 1fr); }
  .shell .field.is-bool { grid-template-columns: minmax(0, 1fr) auto; }
  .shell .field.is-bool .field-l { padding-top: 0; }
  .shell .field-l { padding-top: 0; }
  .shell .citem-body { padding-left: 0; }
  :is(.shell, .ops) .ov-cols, :is(.shell, .ops) .cols2, .shell .builder { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .shell .savebar { left: 12px; right: 12px; bottom: 12px; }
  /* builder: Edit / Preview tabs */
  .shell .b-view { display: flex; margin-bottom: -24px; }
  .shell .b-side { position: static; }
  .shell .builder[data-view="edit"] :is(.b-screen, .b-send) { display: none; }
  .shell .builder[data-view="preview"] :is(.b-form, .b-emoji) { display: none; }
}

/* ---------- phone ---------- */
@media (max-width: 760px) {
  :is(.picker, .ops) .dtop-user { display: none; }
  :is(.picker, .ops) .dtop-end { gap: 6px; }
  .picker .prow { grid-template-columns: 48px minmax(0, 1fr) auto; grid-template-areas: "icon name act" "icon badge act"; gap: 4px 14px; }
  .picker .prow .gicon { grid-area: icon; width: 48px; height: 48px; border-radius: 14px; }
  .picker .prow-name { grid-area: name; font-size: 20px; }
  .picker .prow .badge { grid-area: badge; justify-self: start; min-height: 26px; padding: 2px 10px; }
  .picker .prow .btn { grid-area: act; }
  .shell .onoff-word { font-size: 24px; }
  .shell .tabs { margin-inline: -16px; padding-inline: 16px; }
  .shell .savebar { gap: 6px; padding-left: 18px; font-size: 14.5px; }
  .shell .savebar .btn { padding: 0 12px; }
  .shell .onoff-word { text-align: left; }
  :is(.shell, .ops) .figures div { padding: 18px 0; }
  :is(.shell, .ops) .cols3 { grid-template-columns: minmax(0, 1fr); }
  :is(.shell, .ops) .cbars { gap: 2px; margin-right: 40px; }
  :is(.shell, .ops) .chart .axis { margin-right: 40px; }
  .shell .coll-head { display: none; }
  .shell .coll-row { grid-template-columns: minmax(0, 1fr) 36px; gap: 10px 12px; padding: 14px 0; }
  .shell .coll-cell { grid-column: 1; }
  .shell .coll-cell.is-bool { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .shell .coll-cl { display: block; margin-bottom: 6px; font-size: var(--fs-label); font-weight: 600; color: var(--smoke); }
  .shell .coll-cell.is-bool .coll-cl { margin: 0; }
  .shell .coll-x { grid-column: 2; grid-row: 1; align-self: start; }
  .shell .pair { grid-template-columns: minmax(0, 1fr); }
  .shell .attention-list { padding: 2px 16px; }
  .shell .attention-row { flex-wrap: wrap; }
  .shell .attention-t { flex-basis: calc(100% - 34px); }
  .shell .attention-row .btn { margin-left: 34px; }
  .ops .col-opt { display: none; }
  .ops .srv .gicon { width: 32px; height: 32px; }
  .ops .srv-acts { flex-direction: column; }
  .ops .srv-t b { white-space: normal; overflow-wrap: anywhere; }
  .ops .srvtable :is(th, td).acts { padding-left: 12px; }
  .ops .srv-acts .btn { padding: 0 12px; }
  .ops .statusrow .btn { margin-left: 0; }
}
