/* Type workbench follows the bundled Worldrig/Borozdov dark and light palette. */
:is(.workspace-leaf-content, .wl-page)[data-type="world-builder-types"] :is(.view-header, .wl-page-header) { display: none; }
.wt-surface { padding: 0; overflow: auto; display: flex; flex-direction: column; background: var(--wl-bg); color: var(--wl-text); font-family: var(--wl-font-ui); }
.wt-surface * { box-sizing: border-box; }
.wt-surface h1,.wt-surface h2,.wt-surface h3,.wt-orbis-panel h2,.wt-orbis-panel h3 { margin: 0; font-family: var(--wl-font-ui); line-height: 1.25; }
.wt-surface h2:where(:not([class])) { font-family: var(--wl-font-title); font-weight: 400; letter-spacing: 0; font-size: var(--t-title-page); }
.wt-surface h3 { font-size: 14px; font-weight: 600; }
.wt-surface p,.wt-orbis-panel p { line-height: 1.6; }
.wt-muted { color: var(--wl-text-2); }
.wt-small { font-size: 12px; }
.wt-eyebrow { display: block; font-size: 10px; letter-spacing: .11em; font-weight: 600; color: var(--wl-text-3); text-transform: uppercase; }
.wt-header { padding: 24px 28px 16px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--wl-line); }
.wt-header-title { min-width: 0; }
.wt-header-title h2 { overflow-wrap: anywhere; }
.wt-header-title p { font-size: 13px; margin: 7px 0 0; }
.wt-breadcrumb { display: flex; align-items: center; gap: 9px; margin-bottom: 13px; font-size: 12px; color: var(--wl-text-3); }
.wt-breadcrumb > span:last-child { max-width: 220px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wt-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.wt-actions button { white-space: nowrap; }
.wt-text-button { background: none !important; box-shadow: none !important; color: var(--wl-text-2); padding: 3px 0; height: auto; }
.wt-text-button:hover { color: var(--wl-text); }
.wt-status { margin: 0; padding: 0 28px; min-height: 22px; font-size: 11px; line-height: 22px; color: var(--wl-text-3); white-space: pre-wrap; }
.wt-status:empty { min-height: 8px; }
.wt-status.is-error,.wt-inline-error { color: var(--wl-danger); }
.wt-inline-error { white-space: pre-wrap; font-size: 13px; line-height: 1.5; }

.wt-card { border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); overflow: hidden; }
.wt-portrait { position: relative; min-height: 140px; height: clamp(150px,19vw,210px); background: var(--wl-surface); border-bottom: 1px solid var(--wl-line); display: flex; justify-content: center; align-items: center; overflow: hidden; }
.wt-portrait::before { content: ''; position: absolute; width: 110px; height: 110px; border: 1px solid var(--wl-line); border-radius: 50%; }
.wt-portrait::after { content: ''; position: absolute; width: 145px; height: 145px; border: 1px solid var(--wl-line); border-radius: 50%; opacity: .55; }
.wt-portrait img { width: 100%; height: 100%; object-fit: cover; position: relative; z-index: 1; }
.wt-initials { color: var(--wl-text-2); font-size: 32px; font-weight: 300; letter-spacing: .07em; }
.wt-portrait-caption { position: absolute; bottom: 15px; font-size: 8px; letter-spacing: .18em; color: var(--wl-text-3); }
.wt-card-heading { padding: 22px 24px 10px; }
.wt-card-heading h1 { font-size: clamp(23px,2.2vw,32px); font-weight: 550; letter-spacing: -.6px; margin-top: 8px; overflow-wrap: anywhere; }
.wt-card-summary { color: var(--wl-text-2); font-size: 13px; line-height: 1.65; }
.wt-block { padding: 18px 24px; border-top: 1px solid var(--wl-line); }
.wt-block h3 { margin-bottom: 13px; font-size: 10px; text-transform: uppercase; letter-spacing: .09em; color: var(--wl-text-3); }
.wt-block-content { display: grid; gap: 12px; }
.wt-block-stats .wt-block-content { grid-template-columns: repeat(auto-fit,minmax(95px,1fr)); }
.wt-value { display: flex; flex-direction: column; align-items: flex-start; text-align: start; padding: 8px 10px; height: auto; min-width: 0; white-space: normal; background: transparent; box-shadow: none; border: 1px solid transparent; border-radius: var(--r-sm); color: var(--wl-text); }
button.wt-value:hover { background: var(--wl-raised); }
.wt-surface button.wt-value { background: transparent !important; box-shadow: none !important; }
.wt-surface button.wt-value:hover { background: var(--wl-raised) !important; }
.wt-surface button.wt-value.is-selected { background: var(--wl-raised) !important; }
.wt-value.is-selected { border-color: var(--wl-selection); background: var(--wl-raised); }
.wt-value-label { font-size: 11px; color: var(--wl-text-3); margin-bottom: 7px; }
.wt-value-content { font-size: 13px; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.wt-block-stats .wt-value-content { font-size: 18px; line-height: 1.3; }
.wt-reach { display: inline-flex; font-size: 9px; margin-top: 8px; padding: 2px 5px; border-radius: var(--r-xs); color: var(--wl-text-3); border: 1px solid var(--wl-line); }
.wt-concealed { opacity: .6; }
.wt-card-compact .wt-portrait { height: 100px; min-height: 100px; }
.wt-card-document { border: none; border-radius: 0; }
.wt-card-custom { position: relative; overflow: visible; border: none; border-radius: 0; background: transparent; }
.wt-card-custom .wt-widget { display: block; width: 100%; border: 0; margin: 0; }
/* A page written by hand redraws in a new frame that loads behind the old one. */
.wt-widget.is-loading { position: absolute; top: 0; left: 0; visibility: hidden; pointer-events: none; }
/* Clicking a value there: a menu opens at its place, or a box is typed over it
   in the value's own font and colour (entry-page frameInput). */
.wt-frame-anchor { position: absolute; pointer-events: none; }
.wt-frame-input { position: absolute; z-index: 12; box-sizing: border-box; display: flex; align-items: center; gap: 6px; padding: 4px 9px; border: 1.5px solid var(--wl-selection); border-radius: var(--r-md); background: var(--wl-surface); box-shadow: 0 0 0 3px color-mix(in srgb, var(--wl-selection) 20%, transparent), var(--wl-elev-pop); color: var(--wl-text); }
/* A long value (Markdown) is typed on the panel's own surface, so nothing shows through; the page bar stays above it. */
.wt-frame-input.is-long { align-items: stretch; padding: 8px 10px; background: var(--wl-surface); }
/* Interactive list/chip popover in View mode */
.wt-frame-input.is-list { flex-direction: column; align-items: stretch; gap: 10px; padding: 12px; border: 1px solid var(--wl-line-strong); border-radius: var(--r-lg); background: color-mix(in srgb, var(--wl-surface) 96%, var(--wl-raised)); box-shadow: var(--wl-elev-pop); font: 400 13px/1.4 var(--wl-font-ui); text-align: left; }
.wt-frame-list-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.wt-frame-list-title { color: var(--wl-text-2); font-size: 11.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.wt-surface .wt-frame-list-done { height: 26px; padding: 0 11px; border: 0; border-radius: var(--r-sm); background: var(--wl-accent); color: var(--wl-on-accent); font-size: 12px; font-weight: 600; box-shadow: none; }
.wt-surface .wt-frame-list-done:hover { background: var(--wl-highlight, var(--wl-accent)); }
/* Reusable interactive list & chip editor (Edit form + View inline popover) */
.wt-list-editor { display: flex; flex-direction: column; gap: 8px; padding: 8px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-inset); }
.wt-frame-input.is-list .wt-list-editor { padding: 0; border: 0; background: transparent; }
.wt-list-items { display: flex; flex-wrap: wrap; gap: 6px; }
.wt-list-items[hidden] { display: none; }
.wt-list-editor.is-checklist .wt-list-items { flex-direction: column; flex-wrap: nowrap; gap: 5px; }
.wt-list-chip { display: inline-flex; align-items: center; gap: 2px; max-width: 100%; min-height: 28px; padding: 2px 4px 2px 10px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text); font-size: 12.5px; line-height: 1.3; transition: border-color var(--wl-quick) var(--wl-ease); }
.wt-list-chip:hover { border-color: var(--wl-line-strong); }
.wt-list-chip.is-editing { padding: 2px 8px; border-color: var(--wl-selection); background: var(--wl-surface); }
.wt-surface .wt-list-chip-text { all: unset; box-sizing: border-box; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--wl-text); font: 500 12.5px/1.3 var(--wl-font-ui); cursor: text; padding-right: 4px; }
.wt-surface .wt-list-chip-text:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 2px; border-radius: var(--r-xs); }
.wt-surface .wt-list-chip-input { min-width: 90px; width: 180px; max-width: 100%; height: 22px; padding: 0 2px; border: 0; background: transparent; color: var(--wl-text); font: 500 12.5px/1.3 var(--wl-font-ui); outline: none; box-shadow: none; }
.wt-list-step { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-surface); }
.wt-list-step.is-done .wt-list-step-input { text-decoration: line-through; color: var(--wl-text-3); }
.wt-list-step.is-failed .wt-list-step-input { color: var(--wl-danger); }
.wt-surface .wt-list-step-state { all: unset; display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: var(--r-xs); color: var(--wl-text-2); cursor: pointer; flex-shrink: 0; }
.wt-surface .wt-list-step-state:hover { background: var(--wl-raised); color: var(--wl-text); }
.wt-list-step.is-done .wt-list-step-state { color: var(--wl-success); }
.wt-list-step.is-failed .wt-list-step-state { color: var(--wl-danger); }
.wt-list-step-state .wt-glyph { width: 15px; height: 15px; }
.wt-surface .wt-list-step-input { flex: 1; min-width: 0; height: 26px; padding: 0 4px; border: 0; background: transparent; color: var(--wl-text); font-size: 13px; box-shadow: none; }
.wt-surface .wt-list-step-input:focus { outline: none; }
.wt-surface .wt-list-remove { all: unset; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: var(--wl-text-3); cursor: pointer; flex-shrink: 0; transition: background-color var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-list-remove:hover { background: color-mix(in srgb, var(--wl-danger) 18%, transparent); color: var(--wl-danger); }
.wt-list-remove .wt-glyph { width: 12px; height: 12px; }
.wt-list-entry { display: flex; align-items: center; gap: 6px; }
.wt-surface .wt-list-add-input { flex: 1; min-width: 0; height: 32px; padding: 0 10px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-surface); color: var(--wl-text); font-size: 13px; box-shadow: none; }
.wt-surface .wt-list-add-input:focus { border-color: var(--wl-selection); outline: none; box-shadow: 0 0 0 2px color-mix(in srgb, var(--wl-selection) 20%, transparent); }
.wt-surface .wt-list-add-btn { display: inline-flex; align-items: center; gap: 5px; height: 32px; padding: 0 11px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-raised); color: var(--wl-text); font-size: 12.5px; font-weight: 500; box-shadow: none; flex-shrink: 0; }
.wt-surface .wt-list-add-btn:hover { border-color: var(--wl-line-strong); background: color-mix(in srgb, var(--wl-text) 10%, var(--wl-raised)); }
.wt-list-add-btn .wt-glyph { width: 14px; height: 14px; }
.wt-frame-input.is-done { pointer-events: none; animation: wt-frame-input-out var(--wl-short-out) ease-out var(--wl-page) forwards; }
@keyframes wt-frame-input-out { to { opacity: 0; visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { .wt-frame-input.is-done { animation-duration: 1ms; } }
.wt-frame-input > span { opacity: .6; }
.wt-surface .wt-frame-input:not(.is-list) :is(input, textarea), .wt-surface .wt-frame-input:not(.is-list) :is(input, textarea):is(:hover, :focus, :focus-visible, :active) { flex: 1; width: auto; min-width: 0; height: auto; margin: 0; padding: 0; border: 0; border-radius: 0; outline: none; box-shadow: none; background: transparent; color: inherit; font: inherit; line-height: inherit; text-align: inherit; }
.wt-surface .wt-frame-input:not(.is-list) textarea { resize: none; overflow: hidden; }

.wt-control { display: flex; flex-direction: column; gap: 7px; margin: 14px 0; font-size: 11px; font-weight: 500; color: var(--wl-text-3); }
.wt-control input:not([type="checkbox"]),.wt-control textarea,.wt-control select { width: 100%; min-width: 0; font-family: var(--wl-font-ui); font-size: 13px; color: var(--wl-text); }
.wt-control textarea { min-height: 88px; resize: vertical; line-height: 1.6; }
.wt-control input[type="file"] { padding: 0; border: 0; background: none; font-size: 12px; color: var(--wl-text-2); }
.wt-control input[type="file"]::file-selector-button { margin-right: 10px; padding: 5px 14px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-surface); color: var(--wl-text); font: inherit; cursor: pointer; transition: background-color var(--wl-quick); }
.wt-control input[type="file"]::file-selector-button:hover { background: var(--wl-raised); }

.wt-layout-row { display: flex; align-items: center; gap: 10px; padding: 14px 0; border-bottom: 1px solid var(--wl-line); font-size: 12px; }
.wt-layout-row button { margin-inline-start: auto; }
.wt-layout-row strong { overflow-wrap: anywhere; }

.wt-control textarea.wt-code{ font-family: var(--wl-font-mono); font-size: 11px; line-height: 1.8; }

/* The frame paints the page colour behind a card; the card's own page inside it is see-through
   (card.mjs), so a page with a glow at its top (D-109) can show it around the card. */
.wt-widget { display: block; width: 100%; min-height: 170px; border: 0; border-top: 1px solid var(--wl-line); background: var(--wl-bg); }
.wt-library { padding: 24px 28px; flex: 1; }
.wt-type-row { display: flex; align-items: center; gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--wl-line); }
.wt-type-row p { margin: 7px 0 0; font-size: 12px; }
.wt-type-row .wt-actions,.wt-type-row > button:last-child { margin-inline-start: auto; }
.wt-type-symbol { display: grid; place-items: center; width: 42px; height: 42px; flex-shrink: 0; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-md); font-size: 24px; color: var(--wl-text-2); }
.wt-empty { max-width: 520px; margin: 48px auto; padding: 30px; text-align: center; }
.wt-empty h2 { font-size: 22px; }
.wt-empty p { font-size: 14px; }
.wt-empty .wt-actions { justify-content: center; margin-top: 25px; }
.wt-empty-symbol { display: block; font-size: 42px; color: var(--wl-text-3); margin-bottom: 22px; }
.wt-prototype-note { font-size: 11px; color: var(--wl-text-3); margin-top: 36px; }
.wt-collection-toolbar { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; }
.wt-search { flex: 1; max-width: 400px; min-width: 100px; }
.wt-collection-toolbar > .wt-muted { font-size: 12px; }
.wt-segment { display: flex; gap: 2px; margin-inline-start: auto; padding: 3px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); }
.wt-segment button { box-shadow: none; background: none; font-size: 11px; height: 26px; color: var(--wl-text-3); }
.wt-segment button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); }
.wt-entry-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(190px,1fr)); gap: 18px; }
.wt-entry-card { padding: 0; height: auto; display: flex; flex-direction: column; text-align: start; background: var(--wl-bg); box-shadow: none; border: 1px solid var(--wl-line); border-radius: var(--r-md); overflow: hidden; white-space: normal; }
.wt-entry-card:hover { border-color: var(--wl-line-strong); background: var(--wl-surface); }
.wt-portrait-small { width: 100%; height: 155px; min-height: 155px; }
.wt-portrait-small::before { width: 70px; height: 70px; }
.wt-portrait-small::after { width: 100px; height: 100px; }
.wt-entry-card-text { padding: 15px 16px; width: 100%; }
.wt-entry-card h3 { margin-top: 8px; font-size: 15px; overflow-wrap: anywhere; }
.wt-entry-card p { font-size: 12px; margin: 8px 0 0; }
.wt-entry-grid.is-list { grid-template-columns: 1fr; gap: 8px; }
.wt-entry-grid.is-list .wt-entry-card { flex-direction: row; align-items: center; }
.wt-entry-grid.is-list .wt-portrait-small { width: 65px; min-width: 65px; height: 70px; min-height: 70px; border: 0; }
.wt-entry-grid.is-list .wt-portrait::before,.wt-entry-grid.is-list .wt-portrait::after { display: none; }
.wt-empty-collection { grid-column: 1/-1; }
.wt-entry-page { max-width: 820px; width: 100%; margin: 0 auto; padding: 22px 36px 48px; }
.wt-entry-form { max-height: 65vh; overflow: auto; padding: 0 4px 6px; }
.wt-entry-form .wt-actions { position: sticky; bottom: -6px; padding: 16px 0 4px; background: var(--wl-bg); }
.wt-folder-count { margin-inline-start: auto; font-size: 10px; color: var(--wl-text-3); padding: 0 7px; }
.wt-type-folder { cursor: pointer; }
.wt-type-folder .nav-folder-title-content { color: var(--wl-text); }
.wt-proposed { border: 1px dashed var(--wl-selection); border-radius: var(--r-sm); margin: 15px; padding: 14px; font-size: 12px; }
.wt-proposed strong { display: block; margin-top: 7px; }
.wt-proposed p { font-size: 11px; color: var(--wl-text-3); }

.wt-surface button:focus-visible,.wt-surface input:focus-visible,.wt-surface select:focus-visible,.wt-surface textarea:focus-visible,.wt-orbis-panel button:focus-visible,.wt-orbis-orb:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 2px; }

:is(.workspace-leaf-content, .wl-page)[data-type="world-builder-types"] { container-type: inline-size; }
@container (max-width: 560px) { .wt-header { flex-direction: column; align-items: flex-start; padding: 20px; }     .wt-library { padding: 20px; } .wt-type-row { flex-wrap: wrap; } .wt-collection-toolbar { flex-wrap: wrap; } .wt-entry-page { padding: 18px; }  }

/* Type definitions have one home: Settings; each type opens in its own workspace tab. */
.wb-settings-page .vertical-tab-content.wt-types-settings, .wl-ui.wl-settings .wl-settings-section.wt-types-settings { padding: 0; height: 100%; max-width: none; min-width:0; container-type: inline-size; }

.wt-draft-heading { margin-top: 32px; color: var(--wl-text-2); }

.wt-types-settings .wt-card-heading h1 { display: block !important; font-size: 26px; line-height: 1.25; margin-top: 8px; }

.wt-settings-library { box-sizing:border-box;min-width:0;width: min(860px,100%); margin-inline:auto; padding: 42px 46px 70px; }
.wt-settings-library > h2 { font-size: var(--t-title-page); letter-spacing: 0; }
.wt-settings-library > p { margin: 10px 0 34px; max-width: 650px; font-size: 14px; }
.wt-type-list-tools { display: grid; grid-template-columns: minmax(220px,1fr) 220px auto; gap: 12px; align-items: center; margin-bottom: 20px; }
.wt-type-list-tools input,.wt-type-list-tools select { width: 100%; height: 42px; }
.wt-type-list { display: grid;grid-template-columns:minmax(0,1fr); gap: 10px; }
.wt-type-list .wt-type-row,.wt-settings-library > .wt-type-row { padding: 16px 18px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-surface); }
.wt-type-icon { display: grid; place-items: center; width: 46px; height: 46px; flex: 0 0 46px; border: 1px solid var(--wl-line-strong); border-radius: var(--r-md); color: var(--wl-text-2); background: var(--wl-bg); font: 12px var(--wl-font-mono); }
.wt-type-copy { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.wt-type-copy strong { font-size: 16px; }
.wt-type-meta { color: var(--wl-text-3); font-size: 9px; letter-spacing: .1em; }

.wt-layout-drop { height: 17px; padding: 0 12px; font-size: 10px; text-align: center; color: transparent; line-height: 17px; transition: height var(--wl-quick); }
.wt-layout-drop.is-over{ height: 38px; line-height: 38px; border: 1px dashed var(--wl-selection); color: var(--wl-text-2); background: var(--wl-surface); }
.wt-layout-drop.is-over { color: var(--wl-selection); }

.wt-block-tools { display: flex; align-items: center; gap: 9px; font-size: 9px; color: var(--wl-text-3); padding: 4px 0 12px; opacity: 0; }
.wt-block:hover .wt-block-tools,.wt-block-selected .wt-block-tools,.wt-block:focus-within .wt-block-tools { opacity: 1; }
.wt-block-tools button { min-width: 23px; min-height: 23px; font-size: 14px; }
.wt-block-tools button:first-child { cursor: grab; }
.wt-block-tools button:nth-last-child(2) { margin-inline-start: auto; }
.wt-field-drop { outline: 2px dashed var(--wl-selection) !important; background: var(--wl-raised) !important; }

.wt-drag-ghost { position: fixed; z-index: 999; pointer-events: none; max-width: 200px; padding: 9px 14px; border: 1px solid var(--wl-selection); border-radius: var(--r-sm); color: var(--wl-text); background: var(--wl-surface); box-shadow: var(--wl-elev-pop); font: 12px var(--wl-font-ui); }
.wt-block-placeholder { padding: 12px; border: 1px dashed var(--wl-line); border-radius: var(--r-sm); font-size: 11px; color: var(--wl-text-3); }
.wt-block-heading h3 { font-size: 19px; color: var(--wl-text); letter-spacing: -.3px; text-transform: none; }
.wt-block-divider { border-top: 0; padding-block: 10px; }
.wt-block-divider hr { margin: 0; border-color: var(--wl-line); }
.wt-block-callout { background: var(--wl-surface); }


@container (max-width: 700px) { .wt-type-list-tools { grid-template-columns: 1fr; } .wt-settings-library { padding: 28px 24px 50px; }  }

@media (prefers-reduced-motion: reduce) { .wt-layout-drop { transition: none; } }

/* ── Engine pass: content view, type cards, the New file picker ── */
:is(.workspace-leaf-content, .wl-page)[data-type="world-builder-collection"] :is(.view-header, .wl-page-header) { display: none; }
:is(.workspace-leaf-content, .wl-page)[data-type="world-builder-collection"] { container-type: inline-size; }
.wt-content-header { padding: 28px 32px 20px; }
.wt-content-header .wt-breadcrumb { margin-bottom: 8px; }
.wt-content-header .wt-header-title h2 { font-size: var(--t-title-page); letter-spacing: 0; }
.wt-entry-card { border-radius: var(--r-xl); overflow: hidden; }
.wt-type-card { min-width:0;display: flex; align-items: center; gap: 16px; padding: 16px 18px; border: 1px solid var(--wl-line); border-radius: var(--r-xl); background: var(--wl-surface); }
.wt-type-card.is-builtin { background: transparent; border-style: dashed; }
.wt-type-card .wt-type-copy { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.wt-type-card .wt-type-copy strong { font-size: 16px; font-weight: 600; }
.wt-type-card .wt-type-copy p { margin: 0; font-size: 12px; }
.wt-type-card .wt-actions { margin-inline-start: auto; flex-wrap: nowrap; }
.wt-type-icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex-shrink: 0; border-radius: var(--r-md); border: 1px solid var(--wl-line); background: var(--wl-bg); color: var(--wl-text-2); font-family: var(--wl-font-mono); font-size: 13px; }
.wt-type-meta { font-size: 10px; font-weight: 600; letter-spacing: .14em; color: var(--wl-text-3); }
/* ── Craft-referenced pass: compact bars, icon actions, image-led cards ── */
.wt-glyph, .wt-type-icon { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.wt-glyph svg { width: 16px; height: 16px; display: block; }
body button.wt-icon-button { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border: 1px solid transparent; border-radius: var(--r-md); background: transparent; box-shadow: none; color: var(--wl-text-2); transition: background-color var(--wl-quick), color var(--wl-quick); }
body button.wt-icon-button:hover, body button.wt-icon-button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); }
button > .wt-glyph:first-child svg { width: 14px; height: 14px; }
button.mod-cta > .wt-glyph:first-child { margin-inline-end: 6px; }

/* Collection: title and count, then one toolbar row. */
.wt-collection-head { padding: 26px 28px 0; }
.wt-collection-head h2 { margin: 0; }
.wt-collection-head p { margin: 4px 0 0; font-size: 12px; }
.wt-collection-head + .wt-library { padding-top: 18px; }
.wt-collection-toolbar { gap: 8px; margin-bottom: 20px; }
.wt-collection-toolbar .wt-search { max-width: none; height: 34px; }
.wt-segment.wt-view-toggle { margin-inline-start: 0; padding: 2px; gap: 2px; border-radius: var(--r-md); }
.wt-segment.wt-view-toggle button.wt-icon-button { width: 28px; height: 28px; border-radius: var(--r-sm); }
.wt-collection-toolbar button.mod-cta { height: 34px; }

/* Image-led cards: the portrait fills the card, the type sits on it, the name below. */
.wt-entry-grid { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
body button.wt-entry-card { border-radius: var(--r-lg); background: var(--wl-surface); transition: border-color var(--wl-quick), background-color var(--wl-quick); }
body button.wt-entry-card:hover { background: var(--wl-raised); border-color: var(--wl-line-strong); }
.wt-entry-card .wt-portrait-small { height: auto; min-height: 0; aspect-ratio: 1; border-bottom: 0; background: var(--wl-inset); }
.wt-entry-card .wt-portrait .wt-eyebrow { position: absolute; left: 10px; bottom: 8px; z-index: 2; font-size: 9px; color: var(--wl-text-3); }
.wt-entry-card .wt-portrait:has(img) .wt-eyebrow { color: var(--wl-on-picture-2); text-shadow: 0 1px 3px var(--wl-picture-shade); }
.wt-entry-card .wt-portrait:has(img)::before, .wt-entry-card .wt-portrait:has(img)::after { display: none; }
.wt-entry-card-text { padding: 9px 12px 10px; }
.wt-entry-card h3 { margin: 0; font-size: var(--t-title-card); font-weight: 600; }
.wt-entry-grid:not(.is-list) .wt-entry-card p { display: none; }
.wt-entry-grid.is-list .wt-entry-card .wt-portrait-small { width: 44px; min-width: 44px; height: 44px; aspect-ratio: auto; margin: 6px; border-radius: var(--r-md); }
.wt-entry-grid.is-list .wt-portrait .wt-eyebrow { display: none; }
.wt-entry-grid.is-list .wt-initials { font-size: 13px; }
.wt-entry-grid.is-list .wt-entry-card p { margin-top: 2px; }

/* Folders inside a type's folder, picking files, and moving them (D-110, collection.mjs). */
.wt-collection-head h2 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
body .wt-collection-head button.wt-crumb { height: auto; margin: 0 -4px; padding: 0 4px; border: 0; border-radius: var(--r-xs); background: transparent; box-shadow: none; color: var(--wl-text-3); font: inherit; letter-spacing: inherit; cursor: pointer; transition: color var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); }
body .wt-collection-head button.wt-crumb:hover { background: transparent; color: var(--wl-text); }
body .wt-collection-head button.wt-crumb.is-drop { background: var(--wl-selection-soft); color: var(--wl-text); }
.wt-crumb-gap { color: var(--wl-text-3); font-weight: 400; }
.wt-folder-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-bottom: 12px; }
.wt-folder-grid[hidden] { display: none; }
.wt-folder-tile, body button.wt-folder-tile { box-sizing: border-box; display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 12px 0 10px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-surface); box-shadow: none; color: var(--wl-text); text-align: start; white-space: normal; transition: border-color var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); }
body button.wt-folder-tile:hover { border-color: var(--wl-line-strong); background: var(--wl-raised); }
.wt-folder-tile.is-drop, body button.wt-folder-tile.is-drop { border-color: var(--wl-selection); background: var(--wl-selection-soft); }
.wt-folder-glyph { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-md); background: var(--wl-inset); color: var(--wl-text-2); }
.wt-folder-glyph svg { width: 16px; height: 16px; }
.wt-folder-text { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.wt-folder-name { overflow: hidden; font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.wt-folder-files { color: var(--wl-text-3); font-size: 11px; }
.wt-folder-tile input.wt-folder-name-input { box-sizing: border-box; width: 100%; height: 24px; padding: 0 6px; border: 1px solid var(--wl-selection); border-radius: var(--r-xs); background: var(--wl-inset); color: var(--wl-text); font-size: 13px; box-shadow: none; }
.wt-folder-problem { color: var(--wl-danger); font-size: 11px; }
.wt-folder-problem:empty { display: none; }
.wt-folder-tile:has(.wt-folder-problem:not(:empty)) { height: auto; min-height: 52px; padding-block: 6px; }
.wt-folder-grid.is-list { grid-template-columns: 1fr; gap: 8px; margin-bottom: 8px; }
.wt-folder-grid.is-list .wt-folder-tile { height: 58px; padding-left: 6px; }
.wt-folder-grid.is-list .wt-folder-glyph { width: 44px; height: 44px; }
/* A folder is picked as a card is: the round check sits at its right end (2026-11-03). */
.wt-folder-tile { position: relative; }
.wt-folder-tile .wt-pick { top: 50%; left: auto; right: 12px; translate: 0 -50%; border-color: var(--wl-text-3); background: transparent; }
.wt-folder-tile:hover .wt-pick, .wt-folder-tile:focus-visible .wt-pick, .wt-folder-grid.is-picking .wt-pick { opacity: 1; }
.wt-folder-tile .wt-pick:hover { border-color: var(--wl-text); }
.wt-folder-tile.is-picked .wt-pick { border-color: var(--wl-selection); background: var(--wl-selection); color: var(--wl-on-accent); }
body button.wt-folder-tile.is-picked, body button.wt-folder-tile.is-picked:hover { border-color: var(--wl-selection); box-shadow: 0 0 0 1px var(--wl-selection); }
.wt-folder-grid.is-dragging .wt-folder-tile.is-picked { opacity: .5; }
.wt-folder-tile:has(.wt-pick) .wt-folder-text { padding-right: 28px; }
.wt-entry-card { position: relative; }
.wt-entry-card-folder { display: block; margin-top: 2px; overflow: hidden; color: var(--wl-text-3); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
/* The round check: on a card pointed at, and on every card while any is picked. */
.wt-pick { position: absolute; z-index: 3; top: 8px; left: 8px; display: grid; place-items: center; width: 22px; height: 22px; box-sizing: border-box; border: 1.5px solid color-mix(in srgb, var(--wl-text) 75%, transparent); border-radius: 50%; background: color-mix(in srgb, var(--wl-bg) 35%, transparent); color: transparent; opacity: 0; cursor: pointer; transition: opacity var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease), border-color var(--wl-quick) var(--wl-ease); }
.wt-pick .wt-glyph { display: grid; }
.wt-pick svg { width: 13px; height: 13px; stroke-width: 3; }
.wt-entry-card:hover .wt-pick, .wt-entry-card:focus-visible .wt-pick, .wt-entry-grid.is-picking .wt-pick { opacity: 1; }
.wt-pick:hover { border-color: var(--wl-text); }
.wt-entry-card.is-picked .wt-pick { border-color: var(--wl-selection); background: var(--wl-selection); color: var(--wl-on-accent); }
body button.wt-entry-card.is-picked, body button.wt-entry-card.is-picked:hover { border-color: var(--wl-selection); box-shadow: 0 0 0 1px var(--wl-selection); }
.wt-entry-grid.is-list .wt-pick { top: 50%; left: 17px; translate: 0 -50%; }
.wt-entry-grid.is-dragging .wt-entry-card.is-picked { opacity: .5; }
@media (pointer: coarse) { .wt-pick { opacity: 1; width: 28px; height: 28px; } }
/* While files are picked: what to do with them, floating at the bottom of the page. */
.wt-pick-bar { position: sticky; z-index: 6; bottom: 16px; display: flex; align-items: center; gap: 2px; box-sizing: border-box; width: fit-content; max-width: 100%; margin: 20px auto 0; padding: 5px 5px 5px 16px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: var(--wl-elev-pop); animation: wt-pick-bar-in var(--wl-short) var(--wl-ease-out); }
.wt-pick-bar[hidden] { display: none; }
.wt-pick-count { margin-right: 8px; font-size: 13px; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
body button.wt-pick-action { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 13px; white-space: nowrap; }
body button.wt-pick-action:hover { background: var(--wl-raised); color: var(--wl-text); }
body button.wt-pick-action.is-danger { color: var(--wl-danger); }
body button.wt-pick-action.is-danger:hover { background: color-mix(in srgb, var(--wl-danger) 14%, transparent); }
.wt-pick-action .wt-glyph svg { width: 15px; height: 15px; }
body .wt-pick-bar button.wt-pick-clear { width: 32px; height: 32px; border-radius: 50%; }
@keyframes wt-pick-bar-in { from { opacity: 0; translate: 0 8px; } }
@keyframes wt-pick-bar-fade { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .wt-pick-bar { animation: wt-pick-bar-fade 150ms; } .wt-pick { transition: none; } }
/* The glyph comes first in the button (icons.mjs labelled), so the words after it are the label. Not :has() with a plain
   span after it: Chrome then re-styled every span on the page whenever anything a :has() reads changed. */
@container (max-width: 480px) { .wt-pick-bar .wt-pick-action > .wt-glyph ~ span:not(.wt-glyph) { display: none; } body button.wt-pick-action { padding: 0 9px; } }

/* File page: a slim bar that places the file and acts on it. */
/* Keep the complete header below its tabs, including when the Location panel scrolls. */
.wt-pagebar { position: sticky; top: 0; z-index: 5; flex-shrink: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; min-height: 48px; padding: 8px 12px 8px 18px; border-bottom: 1px solid var(--wl-line); background: var(--wl-bg); }
/* The page's bar is laid out by its own width, so it reads the same in the Files page, the map panel, a tablet and a
   phone. The breadcrumb and the page's tools always share the first row; the breadcrumb gives way first (its folder
   goes in a bar about 300px wide). The page's settings (GM context; a place's Music and Video, entry-page.mjs) sit under them as
   chips, each its name and its choice in one box, as many to a row as fit: one row in a wide panel. A page with only
   GM context keeps it on the first row when there is room. In a bar about 300px wide each chip takes the whole row and
   drops its mark (the choice keeps the room); about 200px wide its name sits over its choice, so the choice is not
   cut. (The widths asked about are inside the bar's padding.) */
.wt-pagebar { container: wt-pagebar / inline-size; }
.wt-pagebar .wt-breadcrumb { margin: 0; gap: 6px; min-width: 0; flex: 1 1 0; }
.wt-pagebar .wt-breadcrumb > :is(.wt-text-button, .wt-crumb-current) { min-width: 0; }
.wt-pagebar .wt-breadcrumb > .wt-text-button { flex: 0 4 auto; overflow: hidden; }
.wt-pagebar .wt-breadcrumb > .wt-text-button > span { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wt-pagebar .wt-crumb-sep { flex-shrink: 0; }
.wt-pagebar .wt-pagebar-tools { order: 1; }
.wt-page-settings { order: 2; flex: 1 1 100%; display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.wt-page-settings:empty { display: none; }
.wt-pagebar .wt-page-settings > .wt-page-context { display: flex; flex-direction: row; align-items: center; gap: 0; flex: 0 1 auto; min-width: 0; max-width: 100%; height: 32px; margin: 0; padding-inline-start: 10px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-inset); color: var(--wl-text-2); font-size: 12px; font-weight: 500; white-space: nowrap; transition: border-color var(--wl-quick) var(--wl-ease); }
.wt-pagebar .wt-page-settings > .wt-page-context:hover { border-color: var(--wl-line-strong); }
.wt-pagebar .wt-page-settings > .wt-page-context:has(button:focus-visible) { outline: var(--wl-focus-outline); outline-offset: 2px; }
.wt-pagebar .wt-page-settings .wl-music-field-label { flex-shrink: 0; }
body.wb-shell .wt-pagebar .wt-page-settings button.wl-music-pick { flex: 0 1 auto; width: auto; height: 30px; gap: 6px; padding: 0 7px 0 6px; border: 0; background: transparent; outline: none; }
@container wt-pagebar (min-width: 640px) {
  .wt-pagebar .wt-page-settings:not(:has(> :nth-child(2))) { order: 0; flex: 0 1 auto; }
}
@container wt-pagebar (max-width: 275px) {
  .wt-pagebar .wt-breadcrumb > :is(.wt-text-button, .wt-crumb-sep) { display: none; }
  .wt-pagebar .wt-page-settings > .wt-page-context { flex: 1 1 100%; }
  body.wb-shell .wt-pagebar .wt-page-settings button.wl-music-pick { flex: 1 1 auto; }
  .wt-pagebar .wt-page-settings .wl-music-pick > .wt-glyph:first-child { display: none; }
}
@container wt-pagebar (max-width: 179px) {
  .wt-pagebar .wt-page-settings .wl-music-pick > .wt-glyph:first-child { display: flex; }
  .wt-pagebar .wt-page-settings > .wt-page-context { flex-direction: column; align-items: stretch; height: auto; padding: 5px 0 1px 10px; }
  .wt-pagebar .wt-page-settings .wl-music-field-label { font-size: 11px; line-height: 14px; }
  body.wb-shell .wt-pagebar .wt-page-settings button.wl-music-pick { height: 26px; padding-inline-start: 0; }
}
.wt-pagebar .wt-page-status:empty { display: none; }
.wt-pagebar .wt-page-status:not(:empty) { order: 3; flex-basis: 100%; margin-inline-start: 0; white-space: normal; overflow-wrap: anywhere; }
.wt-pagebar .wt-breadcrumb .wt-text-button { padding: 2px 4px; color: var(--wl-text-3); font-size: 12px; }
.wt-pagebar .wt-breadcrumb .wt-text-button:hover { color: var(--wl-text); }
.wt-crumb-sep { color: var(--wl-text-3); }
.wt-crumb-current { color: var(--wl-text); font-weight: 500; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wt-pagebar-tools { display: flex; gap: 2px; flex-shrink: 0; }
.wt-pagebar + .wt-entry-page { padding-top: 28px; }

/* File Types list: icon box, meta line, name; the card opens the editor. */
.wt-type-card { gap: 14px; padding: 14px 16px; border-radius: var(--r-md); transition: border-color var(--wl-quick), background-color var(--wl-quick); }
.wt-type-card.is-clickable { cursor: pointer; }
.wt-type-card.is-clickable:hover { border-color: var(--wl-line-strong); background: var(--wl-raised); }
.wt-type-icon { width: 42px; height: 42px; border-radius: var(--r-md); border: 1px solid var(--wl-line); background: var(--wl-inset); color: var(--wl-text-2); }
.wt-type-icon svg { width: 18px; height: 18px; }
.wt-type-icon.is-json { color: var(--wl-accent); background: color-mix(in srgb, var(--wl-accent) 6%, transparent); border-color: color-mix(in srgb, var(--wl-accent) 14%, transparent); }
.wt-type-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.wt-type-meta .wt-glyph svg { width: 12px; height: 12px; }
.wt-type-card-actions { flex-shrink:0;display: flex; gap: 2px; margin-inline-start: auto; }

/* Files tree: sentence case, folder and file icons, a plain count. */
:is(.workspace-leaf-content, .wl-page)[data-type="file-explorer"] .nav-folder-title-content::before,
:is(.workspace-leaf-content, .wl-page)[data-type="file-explorer"] .nav-file-title-content::before { content: ''; display: inline-block; flex-shrink: 0; width: 14px; height: 14px; margin-inline-end: 8px; vertical-align: -2px; background: currentColor; opacity: .7; -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z'/><path d='M14 2v4a2 2 0 0 0 2 2h4M10 9H8M16 13H8M16 17H8'/></svg>") center / contain no-repeat; }
:is(.workspace-leaf-content, .wl-page)[data-type="file-explorer"] .nav-folder-title-content::before { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z'/></svg>"); }
:is(.workspace-leaf-content, .wl-page)[data-type="file-explorer"] .nav-folder:not(.is-collapsed) > .nav-folder-title .nav-folder-title-content::before { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2'/></svg>"); }
:is(.workspace-leaf-content, .wl-page)[data-type="file-explorer"] .nav-file-title.wt-type-file .nav-file-title-content::before { -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z'/><path d='M14 2v4a2 2 0 0 0 2 2h4'/><path d='M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1'/></svg>"); }
.wt-folder-count { margin-inline-start: auto; padding-inline-start: 8px; background: none; color: var(--wl-text-3); font-family: var(--wl-font-mono); font-size: 11px; font-variant-numeric: tabular-nums; }
.wt-settings-library > h2 { margin: 0; padding: 0; }
.wt-type-list-tools { grid-template-columns: minmax(0, 1fr) 180px auto; gap: 8px; }
.wt-type-list-tools input, .wt-type-list-tools select { height: 36px; }
.wt-type-list-tools button.mod-cta { height: 36px; padding-inline: 16px; }
@container (max-width: 700px) { .wt-type-list-tools { grid-template-columns: minmax(0, 1fr) 128px auto; } }
@container (max-width: 360px) { .wt-type-list-tools { grid-template-columns: 1fr; } }
.wt-type-meta { flex-wrap: nowrap; min-width: 0; }
.wt-type-meta > span:last-child { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* File page modes. Edit and Source stay on the page; a floating bar saves. */
.wt-pagebar .wt-view-toggle { margin-inline-start: auto; }
.wt-entry-page.is-edit, .wt-entry-page.is-source { max-width: 720px; padding-bottom: 24px; }
.wt-entry-page.is-edit .wt-entry-form { display: flex; flex-direction: column; max-height: none; overflow: visible; padding: 0; }
.wt-entry-page.is-source { max-width: 960px; display: flex; flex-direction: column; min-height: calc(100% - 40px); }
.wt-source { flex: 1; width: 100%; min-height: 420px; padding: 14px 16px; resize: none; font-family: var(--wl-font-mono); font-size: 12px; line-height: 1.7; tab-size: 2; white-space: pre-wrap; overflow-wrap: anywhere; }
/* Source is a writing surface: it keeps the code font over the shell's font for fields, and shows focus with its
   border instead of a ring around the whole page. */
.wt-entry-page textarea.wt-source { font-family: var(--wl-font-mono); }
.wt-entry-page.is-source textarea.wt-source:focus-visible { outline: none; border-color: var(--wl-selection); }
.wt-entry-page .wt-inline-error:empty { display: none; }
.wt-entry-page .wt-inline-error { white-space: pre-wrap; margin: 0 0 12px; }
.wt-savebar { position: sticky; bottom: 20px; z-index: 6; align-self: center; margin: auto 0 20px; display: flex; gap: 8px; padding: 6px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: var(--wl-elev-pop); }
.wt-savebar button { height: 32px; padding-inline: 16px; }
.wt-savebar[hidden] { display: none; }
.wt-savebar.is-asking { align-items: center; padding-left: 14px; }
.wt-savebar-question { margin-right: 6px; font-size: 13px; }

/* ---- Type workspace (one tab per type) ----
   Same grammar as the map editor: the page in the middle, a floating dock to
   add parts, a control column at the page's edge, and a panel with an icon
   band whose rows show their value and open in place. */
/* The page's own rule (.wl-ui.wl-workspace .wl-page-content: auto) outweighed this one, so the closed settings drawer,
   waiting just off the right edge, gave the editor a sideways scroll bar on a narrow window. */
.wt-surface.wt-ws-surface, .wl-workspace .wl-page-content.wt-surface.wt-ws-surface { padding: 0; overflow: hidden; }
.wt-ws { position: relative; height: 100%; min-height: 0; display: flex; flex-direction: column; container: wt-ws / inline-size; font-size: 13px; }
.wt-ws button { box-shadow: none; }
.wt-ws [hidden] { display: none !important; }
/* Hidden names sit at the top corner of their box: left where they fall, one deep in a long panel lay
   below the window and scrolled the whole editor up to reach it. */
.wt-ws-sr { position: absolute; top: 0; left: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wt-ws-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 46px; padding: 6px 12px 6px 18px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-crumbs { display: flex; align-items: center; gap: 6px; min-width: 0; }
.wt-surface .wt-ws-crumb { background: transparent; height: 26px; padding: 0 6px; margin-left: -6px; color: var(--wl-text-3); font-size: 13px; }
.wt-surface .wt-ws-crumb:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws-crumb-sep { width: 14px; height: 14px; color: var(--wl-text-3); flex-shrink: 0; }
.wt-ws-crumb-sep svg, .wt-ws .wt-glyph svg { width: 100%; height: 100%; display: block; }
.wt-ws-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* When the row is short the name gives way first, then the count (an ellipsis); neither runs under the tabs beside them. */
.wt-surface .wt-ws-files { flex: 0 .05 auto; min-width: 3.2em; overflow: hidden; text-overflow: ellipsis; height: 22px; padding: 0 8px; margin-left: 4px; font-size: 11px; color: var(--wl-text-3); background: var(--wl-raised); border-radius: var(--r-md); white-space: nowrap; }
.wt-ws-title { flex: 0 1 auto; min-width: 2.5em; }
.wt-ws-crumbs > :is(.wt-ws-crumb, .wt-ws-crumb-sep) { flex-shrink: 0; }
.wt-surface .wt-ws-files:hover { color: var(--wl-text); }
.wt-ws-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.wt-ws-status { font-size: 12px; color: var(--wl-text-3); max-width: 340px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* An error is two lines at most, ending in an ellipsis, never cut through a line; the whole of it shows on hover. */
.wt-ws-status.is-error { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; color: var(--wl-danger); white-space: normal; }
.wt-surface .wt-ws-discard { background: transparent; color: var(--wl-text-2); height: 30px; }
.wt-surface .wt-ws-discard:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws-save { height: 30px; min-width: 72px; }
.wt-ws-save:disabled { opacity: .5; cursor: default; }
.wt-ws-panel-toggle, .wt-ws-panel-close { display: none; }
.wt-ws .wt-icon-button { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; background: transparent; color: var(--wl-text-2); border-radius: var(--r-sm); }
.wt-ws .wt-icon-button:hover:not(:disabled) { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws .wt-icon-button[aria-pressed="true"] { color: var(--wl-selection); background: var(--wl-raised); }
.wt-ws .wt-icon-button:disabled { opacity: .35; }
.wt-ws .wt-icon-button .wt-glyph { width: 16px; height: 16px; }
.wt-ws-body { position: relative; flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) 304px; --wt-ws-drawer: 0; }
/* Page */
.wt-ws-stage { position: relative; min-width: 0; min-height: 0; background-color: var(--wl-inset); background-image: radial-gradient(var(--wl-line) .8px, transparent .8px); background-size: 22px 22px; }
.wt-ws-scroll { position: absolute; inset: 0; overflow: auto; padding: 62px 76px 136px 36px; }
.wt-ws-page { max-width: 760px; margin: 0 auto; }
.wt-ws-chips { position: absolute; top: 16px; left: 20px; right: 76px; display: flex; gap: 8px; align-items: center; pointer-events: none; z-index: 3; }
.wt-surface .wt-ws-chip { pointer-events: auto; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; font-size: 12px; color: var(--wl-text-2); background: var(--wl-bg); border: 1px solid var(--wl-line); border-radius: var(--r-lg); max-width: 260px; }
.wt-ws-chip > span:not(.wt-glyph) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-surface .wt-ws-chip:hover { color: var(--wl-text); border-color: var(--wl-line-strong); }
.wt-ws-chip .wt-glyph { width: 14px; height: 14px; flex-shrink: 0; }
.wt-surface .wt-ws-chip.is-viewer { color: var(--wl-selection); border-color: color-mix(in srgb, var(--wl-selection) 45%, transparent); }
.wt-ws-custom-page { position: relative; margin: 0 auto; overflow: hidden; background: var(--wl-bg); border: 1px solid var(--wl-line); border-radius: var(--r-lg); box-shadow: var(--wl-elev-card); }
/* Control column at the page's edge */
.wt-ws-controls { position: absolute; top: 16px; right: 14px; display: flex; flex-direction: column; gap: 8px; z-index: 4; }
.wt-ws-control-group { display: flex; flex-direction: column; padding: 3px; gap: 2px; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-md); box-shadow: var(--wl-elev-pop); }
/* Dock: add parts to the page */
.wt-ws-dock { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; align-items: stretch; gap: 2px; padding: 5px; max-width: calc(100% - 32px); overflow-x: auto; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-md); box-shadow: var(--wl-elev-pop); z-index: 5; scrollbar-width: none; }
.wt-ws-dock .wt-icon-button { flex-direction: column; gap: 3px; width: auto; min-width: 54px; height: 46px; padding: 4px 6px; flex-shrink: 0; }
.wt-ws-dock .wt-icon-button .wt-glyph { width: 17px; height: 17px; }
.wt-ws-dock-label { font-size: 10.5px; line-height: 1; white-space: nowrap; }
.wt-ws-dock .wt-icon-button:last-child { min-width: 36px; }
.wt-ws-dock-sep { width: 1px; margin: 6px 3px; background: var(--wl-line); flex-shrink: 0; }
/* A new type starts with its name only: no page tools until it has one. */
.wt-ws.is-starting .wt-ws-dock, .wt-ws.is-starting .wt-ws-controls, .wt-ws.is-starting .wt-ws-chips, .wt-ws.is-starting .wt-ws-panel, .wt-ws.is-starting .wt-ws-panel-toggle { display: none; }
.wt-ws.is-starting .wt-ws-body { grid-template-columns: minmax(0, 1fr); }
.wt-ws.is-starting .wt-ws-scroll { padding: 48px 24px; }
/* Menus for quick choices (mounted on body, elevated popover surface) */
.wt-ws-menu { position: fixed; z-index: 66; min-width: 248px; max-width: 332px; max-height: min(460px, 74vh); overflow: hidden auto; padding: 6px; background: color-mix(in srgb, var(--wl-surface) 94%, var(--wl-raised)); backdrop-filter: blur(16px) saturate(1.2); border: 1px solid var(--wl-line-strong); border-radius: var(--r-lg); box-shadow: var(--wl-elev-pop); animation: wt-ws-menu-in var(--wl-short, 180ms) var(--wl-ease-out, ease-out); }
@keyframes wt-ws-menu-in { from { opacity: 0; transform: translateY(-4px) scale(.985); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .wt-ws-menu { animation: none; } }
@media (prefers-reduced-transparency: reduce) { .wt-ws-menu { background: var(--wl-surface); backdrop-filter: none; } }
.wt-ws-menu-sep { height: 1px; margin: 6px 4px; background: var(--wl-line); }
.wt-ws-menu-section { padding: 6px 10px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--wl-text-3); }
.wt-ws-menu-note { margin: 4px 10px 6px; font-size: 11.5px; line-height: 1.45; color: var(--wl-text-3); }
.wt-surface .wt-ws-menu-item { box-shadow: none; display: flex; align-items: center; gap: 10px; width: 100%; min-height: 34px; height: auto; padding: 6px 10px; justify-content: flex-start; text-align: left; border: 0; background: transparent; border-radius: var(--r-sm); font-size: 13px; font-weight: 500; color: var(--wl-text); transition: background-color var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-ws-menu-item:hover, .wt-surface .wt-ws-menu-item:focus-visible { background: var(--wl-raised); outline: none; box-shadow: none; }
.wt-surface .wt-ws-menu-item.is-danger { color: var(--wl-danger); }
.wt-surface .wt-ws-menu-item.is-danger > .wt-glyph { color: var(--wl-danger); }
.wt-surface .wt-ws-menu-item.is-danger:hover, .wt-surface .wt-ws-menu-item.is-danger:focus-visible { background: color-mix(in srgb, var(--wl-danger) 14%, transparent); color: var(--wl-danger); }
.wt-ws-menu-item > .wt-glyph { width: 16px; height: 16px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-menu-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.wt-ws-menu-text small { font-size: 11.5px; font-weight: 400; line-height: 1.35; color: var(--wl-text-3); white-space: normal; }
.wt-ws-menu-item .wt-ws-menu-check { color: var(--wl-selection); }
.wt-ws-menu-item .wt-ws-menu-check[hidden] { display: none; }
/* Start: a new type on the page */
.wt-ws-start { max-width: 560px; margin: 4vh auto 0; padding: 28px; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-xl); box-shadow: var(--wl-elev-card); }
.wt-ws-start > p { margin: 8px 0 20px; font-size: 13px; }
.wt-ws-start-name { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 600; color: var(--wl-text-2); }
.wt-ws-start-name input { height: 40px; font-size: 17px; }
.wt-ws-start .wt-ws-start-folder { margin: 7px 0 18px; font-size: 12px; }
.wt-ws-start-label { display: block; margin-bottom: 8px; font-size: 12px; font-weight: 600; color: var(--wl-text-3); }
.wt-ws-start-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.wt-surface .wt-ws-start-option { display: flex; align-items: flex-start; gap: 10px; height: auto; padding: 12px; text-align: left; white-space: normal; background: transparent; border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-surface .wt-ws-start-option:hover { background: var(--wl-raised); }
.wt-surface .wt-ws-start-option[aria-checked="true"] { border-color: var(--wl-selection); background: var(--wl-selection-soft); }
.wt-ws-start-option .wt-glyph { width: 18px; height: 18px; margin-top: 1px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-start-option > span:last-child { display: flex; flex-direction: column; gap: 4px; }
.wt-ws-start-option strong { font-size: 13px; }
.wt-ws-start-option small { font-size: 12px; line-height: 1.45; color: var(--wl-text-3); }
.wt-ws-start .wt-inline-error:empty { display: none; }
.wt-ws-start-footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 22px; }
/* Panel */
.wt-ws-panel { position: relative; min-width: 0; min-height: 0; display: flex; flex-direction: column; background: var(--wl-surface); border-left: 1px solid var(--wl-line); }
.wt-ws-band { display: flex; align-items: center; gap: 4px; padding: 7px 10px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-band .wt-ws-band-tab[aria-selected="true"] { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws-band .wt-ws-panel-close { margin-left: auto; }
.wt-ws-panel-body { flex: 1; min-height: 0; overflow: auto; padding: 4px 14px 92px; }
.wt-ws-panel-head { padding: 12px 2px 10px; }
.wt-ws-panel-head h3 { font-size: 13px; font-weight: 600; }
.wt-ws-panel-head p { margin: 5px 0 0; font-size: 12px; line-height: 1.5; }
.wt-ws-panel-head.is-hint { padding-top: 18px; }
.wt-ws-panel-head .wt-ws-add { margin-top: 12px; height: 30px; font-size: 12px; gap: 6px; }
.wt-ws-panel-head .wt-ws-add .wt-glyph { width: 14px; height: 14px; }
.wt-ws-panel-note { margin: 16px 2px 0; font-size: 12px; line-height: 1.5; color: var(--wl-text-3); }
.wt-ws-panel-note .wt-text-button { display: inline; font-size: 12px; color: var(--wl-text); padding: 0; }
.wt-ws-section { margin: 18px 2px 4px; font-size: 11px; font-weight: 600; letter-spacing: .02em; color: var(--wl-text-3); }
/* Rows: name, current value, and a body that opens in place */
.wt-prop { border-bottom: 1px solid var(--wl-line); }
.wt-prop-name { font-weight: 600; font-size: 12.5px; white-space: nowrap; }
.wt-ws-control input, .wt-ws-control select, .wt-ws-control textarea { width: 100%; font-size: 12.5px; }
.wt-ws-control textarea.wt-code { min-height: 150px; font: 11.5px/1.55 var(--wl-font-mono); }
.wt-ws-hint { margin: 0; font-size: 11.5px; line-height: 1.45; color: var(--wl-text-3); }
.wt-ws-control { display: flex; flex-direction: column; gap: 5px; font-size: 11.5px; font-weight: 500; color: var(--wl-text-3); }
.wt-ws-control-label { font-size: 11.5px; font-weight: 500; color: var(--wl-text-3); margin-bottom: -3px; }
.wt-ws-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.wt-prop-switch { display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 7px 2px 7px 20px; cursor: pointer; }
.wt-prop-switch > .wt-prop-name { display: flex; flex-direction: column; gap: 2px; white-space: normal; }
.wt-prop-switch > .wt-prop-name small { font-weight: 400; font-size: 11.5px; color: var(--wl-text-3); line-height: 1.4; }
:is(.wt-ws, .wt-map) input.wt-switch { appearance: none; -webkit-appearance: none; margin: 0 0 0 auto; flex-shrink: 0; width: 30px; height: 18px; border: 0; border-radius: var(--r-md); background: var(--wl-line-strong); position: relative; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease); }
:is(.wt-ws, .wt-map) input.wt-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--wl-text-2); transition: transform var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); box-shadow: 0 1px 2px color-mix(in srgb, var(--wl-bg) 45%, transparent); }
:is(.wt-ws, .wt-map) input.wt-switch:checked { background: var(--wl-accent); }
:is(.wt-ws, .wt-map) input.wt-switch:checked::after { background: var(--wl-on-accent); }
:is(.wt-ws, .wt-map) input.wt-switch:checked::after { transform: translateX(12px); }
:is(.wt-ws, .wt-map) input.wt-switch:disabled { opacity: .45; cursor: default; }
:is(.wt-ws, .wt-map) input.wt-switch:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 2px; }
.wt-ws-segment { display: flex; padding: 2px; gap: 2px; background: var(--wl-inset); border: 1px solid var(--wl-line); border-radius: var(--r-sm); }
.wt-surface .wt-ws-segment button { flex: 1; height: 26px; padding: 0 6px; font-size: 12px; background: transparent; color: var(--wl-text-2); border-radius: var(--r-sm); white-space: nowrap; }
.wt-surface .wt-ws-segment button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-ws-colour { display: grid; grid-template-columns: 70px 30px 1fr 28px; gap: 6px; align-items: center; font-size: 12px; color: var(--wl-text-2); }
.wt-ws-colour input[type="color"] { width: 30px; height: 28px; padding: 2px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-bg); }
.wt-ws-colour input[type="color"]::-webkit-color-swatch { border: 0; border-radius: var(--r-xs); }
.wt-ws-colour input[type="text"] { height: 28px; font-size: 12px; min-width: 0; }
.wt-ws .wt-ws-colour-reset { width: 28px; height: 28px; }
/* Inspect */
.wt-ws-inspect-head { display: flex; align-items: flex-start; gap: 10px; padding: 14px 2px 6px; }
.wt-ws-inspect-glyph { width: 18px; height: 18px; margin-top: 2px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-inspect-titles { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.wt-ws-inspect-titles h3 { font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.wt-ws-inspect-titles small { font-size: 12px; color: var(--wl-text-3); }
.wt-ws .wt-ws-inspect-close { width: 26px; height: 26px; margin: -3px -4px 0 0; }
.wt-ws-inspect-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.wt-ws-inspect-actions button { height: 30px; font-size: 12px; gap: 6px; }
.wt-ws-inspect-actions .wt-glyph { width: 14px; height: 14px; }
.wt-surface .wt-ws-inspect-actions .wt-ws-remove { background: transparent; color: var(--wl-text-2); }
.wt-surface .wt-ws-inspect-actions .wt-ws-remove:hover { color: var(--wl-danger); background: var(--wl-raised); }
.wt-surface .wt-ws-quiet-action { display: block; margin: 14px 0 0 2px; height: auto; padding: 0; font-size: 12px; color: var(--wl-text-2); background: transparent; }
.wt-surface .wt-ws-quiet-action:hover { color: var(--wl-danger); }
.wt-ws-callout { margin: 8px 0 6px; padding: 12px; border-radius: var(--r-md); background: var(--wl-raised); display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.wt-ws-callout p { margin: 0; font-size: 12px; line-height: 1.5; color: var(--wl-text-2); }
.wt-ws-callout button { height: 30px; font-size: 12px; gap: 6px; }
.wt-ws-callout .wt-glyph { width: 14px; height: 14px; }
.wt-ws-layers { display: flex; flex-direction: column; gap: 1px; margin: 4px -6px 0; }
.wt-surface .wt-ws-layer { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 30px; height: auto; padding: 5px 8px 5px calc(8px + var(--depth, 0) * 14px); justify-content: flex-start; text-align: left; background: transparent; border-radius: var(--r-sm); font-size: 12.5px; color: var(--wl-text); touch-action: none; }
.wt-surface .wt-ws-layer:hover { background: var(--wl-raised); }
.wt-ws-layer .wt-glyph { width: 14px; height: 14px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-layer-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-ws-layer .wt-ws-layer-toggle { width: 14px; height: 14px; flex-shrink: 0; margin-right: -2px; color: var(--wl-text-3); }
.wt-ws-layer .wt-ws-layer-toggle:hover { color: var(--wl-text); }
.wt-ws-layer small { margin-left: auto; font-size: 11px; color: var(--wl-text-3); white-space: nowrap; }
/* Who knows: the reach ladder (D-015), coloured as in the layout system */
[data-reach="Everyone"] { --wt-reach: var(--color-green); }
[data-reach="On sight"] { --wt-reach: var(--color-blue); }
[data-reach="Acquaintances"] { --wt-reach: var(--color-cyan); }
[data-reach="Close"] { --wt-reach: var(--color-yellow); }
[data-reach="Self"] { --wt-reach: var(--color-red); }
[data-reach="Truth"] { --wt-reach: var(--color-purple); }
[data-reach="Not in play"] { --wt-reach: var(--wl-text-3); }
.wt-ws-reach { display: flex; flex-direction: column; gap: 2px; }
.wt-surface .wt-ws-reach-item { display: flex; align-items: flex-start; gap: 10px; width: 100%; height: auto; padding: 7px 8px; justify-content: flex-start; text-align: left; white-space: normal; background: transparent; border-radius: var(--r-sm); border: 1px solid transparent; }
.wt-surface .wt-ws-reach-item:hover { background: var(--wl-raised); }
.wt-surface .wt-ws-reach-item[aria-checked="true"] { border-color: var(--wl-line-strong); background: var(--wl-raised); }
.wt-ws-reach-item > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.wt-ws-reach-item strong { font-size: 12.5px; font-weight: 600; }
.wt-ws-reach-item small { font-size: 11.5px; color: var(--wl-text-3); line-height: 1.35; }
.wt-ws-reach-dot { width: 8px; height: 8px; margin-top: 5px; border-radius: 50%; background: var(--wt-reach, var(--wl-text-3)); flex-shrink: 0; }
/* Fields */
.wt-ws-field-list { display: flex; flex-direction: column; gap: 1px; margin: 0 -6px; }
.wt-surface .wt-ws-field-row, .wt-ws-field-row { display: flex; align-items: center; gap: 9px; width: 100%; min-height: 34px; height: auto; padding: 6px 8px; justify-content: flex-start; text-align: left; background: transparent; border-radius: var(--r-sm); font-size: 12.5px; color: var(--wl-text); }
.wt-surface .wt-ws-field-row:hover { background: var(--wl-raised); }
.wt-surface .wt-ws-field-row.is-selected { background: var(--wl-raised); }
.wt-ws-field-row .wt-glyph { width: 15px; height: 15px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-field-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-ws-badge { font-size: 10.5px; padding: 1px 6px; border-radius: var(--r-md); color: var(--wl-text-3); border: 1px dashed var(--wl-line-strong); white-space: nowrap; }
.wt-ws-reach-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--wl-text-3); white-space: nowrap; }
.wt-ws-reach-chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--wt-reach); }
.wt-ws-hidden { margin-top: 14px; font-size: 12px; color: var(--wl-text-2); }
.wt-ws-hidden > summary { cursor: pointer; padding: 6px 2px; }
.wt-ws-field-row.is-hidden { color: var(--wl-text-2); padding-left: 2px; }
.wt-ws-field-row.is-hidden .wt-text-button { margin-left: auto; font-size: 12px; color: var(--wl-text); }
/* Dragging */
.wt-ws.is-dragging, .wt-ws.is-dragging * { cursor: grabbing !important; user-select: none; }
.wt-ws-drop-line { position: fixed; z-index: 60; pointer-events: none; background: var(--wl-selection); border-radius: var(--r-xs); }
.wt-ws-drop-line.is-inside { background: color-mix(in srgb, var(--wl-selection) 12%, transparent); outline: 2px dashed var(--wl-selection); outline-offset: -2px; border-radius: var(--r-sm); }
/* Boris docked no longer hides an editor's settings (D-028 gave him the right side): when the room is short they fold
   into the editor's own drawer below (D-369), so its settings button always opens them. */
/* Tablet: the panel slides over the page. */
@container wt-ws (max-width: 799px) {
  .wt-ws-body { grid-template-columns: minmax(0, 1fr); --wt-ws-drawer: 1; }
  .wt-ws-panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(320px, 92%); z-index: 20; box-shadow: var(--wl-elev-pop); transform: translateX(104%); visibility: hidden; transition: transform var(--wl-short) var(--wl-ease), visibility 0s linear var(--wl-short); }
  .wt-ws.is-panel-open .wt-ws-panel { transform: none; visibility: visible; transition: transform var(--wl-short) var(--wl-ease); }
  .wt-ws-panel-toggle, .wt-ws-panel-close { display: inline-flex; }
  .wt-ws-scroll { padding: 62px 68px 132px 24px; }
  .wt-ws-status { max-width: 200px; }
  .wt-ws.is-code .wt-ws-body, .wt-ws.is-ai .wt-ws-body { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) minmax(220px, 40%); }
  .wt-ws-code, .wt-ws-ai { border-right: 0; border-bottom: 1px solid var(--wl-line); }
  .wt-ws-view > span:last-child, .wt-ws-orbis > span:last-child { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .wt-surface .wt-ws-view, .wt-surface .wt-ws-orbis { padding: 0 8px; }
}
/* Phone: the panel is a sheet from the bottom; the controls sit in a row. */
@container wt-ws (max-width: 599px) {
  .wt-ws-bar { padding: 6px 8px 6px 12px; }
  .wt-surface .wt-ws-crumb, .wt-ws-crumb-sep, .wt-surface .wt-ws-files, .wt-ws-status { display: none; }
  .wt-ws-panel { top: auto; left: 0; width: auto; height: min(62%, 480px); border-left: 0; border-top: 1px solid var(--wl-line); border-radius: var(--r-xl) var(--r-xl) 0 0; box-shadow: var(--wl-elev-pop); transform: translateY(104%); }
  .wt-ws-scroll { padding: 104px 12px 120px; }
  .wt-ws-chips { top: 60px; left: 12px; right: 12px; }
  .wt-ws-controls { top: 12px; left: 12px; right: 12px; flex-direction: row; justify-content: flex-end; }
  .wt-ws-control-group { flex-direction: row; }
  .wt-ws-dock { bottom: 12px; left: 12px; right: 12px; transform: none; max-width: none; }
  .wt-ws-dock .wt-icon-button { min-width: 44px; }
  .wt-ws-dock-label { display: none; }
  .wt-ws-start { margin-top: 0; padding: 20px; }
  .wt-ws-start-options { grid-template-columns: 1fr; }
  .wt-ws-stage.is-preview .wt-ws-scroll { padding: 60px 12px 24px; }
  .wt-ws-stage.is-preview .wt-ws-chips { top: 12px; right: auto; }
  .wt-ws-code, .wt-ws-ai { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) { .wt-ws-panel, :is(.wt-ws, .wt-map) input.wt-switch, :is(.wt-ws, .wt-map) input.wt-switch::after { transition: none !important; } }

/* ---- Ways to work (D-033): Design · Code · Another AI, and Orbis in its own panel ---- */
.wt-ws-views { display: flex; gap: 2px; padding: 2px; flex-shrink: 0; background: var(--wl-inset); border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-surface .wt-ws-view { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; font-size: 12px; background: transparent; color: var(--wl-text-2); border-radius: var(--r-sm); white-space: nowrap; }
/* On a touch screen the view switch and the breadcrumb are big enough to tap (the sweep, 2026-11-18). */
@media (pointer: coarse) { .wt-surface .wt-ws-view { height: 34px; } .wt-pagebar .wt-breadcrumb .wt-text-button { min-height: 32px; padding: 0 6px; } }
.wt-surface .wt-ws-view:hover { color: var(--wl-text); }
.wt-surface .wt-ws-view[aria-selected="true"] { background: var(--wl-raised); color: var(--wl-text); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-ws-view .wt-glyph, .wt-ws-orbis .wt-glyph { width: 14px; height: 14px; flex-shrink: 0; }
.wt-surface .wt-ws-orbis { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; font-size: 12px; background: transparent; color: var(--wl-text-2); border: 1px solid var(--wl-line); border-radius: var(--r-sm); }
.wt-surface .wt-ws-orbis:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws-orbis .wt-glyph { color: var(--wl-text-2); }
.wt-orbis-other { margin: 0 0 10px; }
.wt-orbis-other .wt-text-button { display: inline; padding: 0; height: auto; font-size: inherit; color: var(--wl-text); background: transparent; }
/* Code and Another AI: a pane beside the page */
@container wt-ws (min-width: 800px) {
  .wt-ws.is-code .wt-ws-body, .wt-ws.is-ai .wt-ws-body { grid-template-columns: minmax(340px, 44%) minmax(0, 1fr); }
  .wt-ws-code, .wt-ws-ai { border-right: 1px solid var(--wl-line); }
}
.wt-ws-code, .wt-ws-ai { min-width: 0; min-height: 0; display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; overflow: auto; background: var(--wl-surface); }
.wt-ws-stage.is-preview .wt-ws-scroll { padding-bottom: 40px; }
/* Code: one bar (the two files, then the tools), a drawer for help or another AI, and the editor. */
.wt-ws-code-bar { display: flex; align-items: flex-end; gap: 8px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-code-tabs { display: flex; gap: 2px; }
.wt-ws-code-tools { display: flex; align-items: center; gap: 2px; margin-inline-start: auto; padding-bottom: 3px; }
.wt-surface .wt-ws-code-tools .wt-ws-code-tool { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 9px; font-size: 12px; color: var(--wl-text-2); background: transparent; border-radius: var(--r-sm); box-shadow: none; transition: background var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-ws-code-tools .wt-ws-code-tool.wt-icon-button { width: 26px; padding: 0; justify-content: center; }
.wt-surface .wt-ws-code-tools .wt-ws-code-tool:hover, .wt-surface .wt-ws-code-tools .wt-ws-code-tool[aria-expanded="true"] { color: var(--wl-text); background: var(--wl-raised); }
.wt-surface .wt-ws-code-tools .wt-ws-code-tool[hidden] { display: none; }
/* Scripts tab (D-150): which script, and the rules to copy for another AI under the help. */
.wt-surface .wt-ws-code-tools .wt-ws-code-pick { order: -1; height: 26px; max-width: 200px; margin-inline-end: 6px; padding: 0 26px 0 9px; font-size: 12px; }
.wt-surface .wt-ws-code-tools .wt-ws-code-pick[hidden] { display: none; }
.wt-surface .wt-ws-code-drawer .wt-ws-code-copy-rules { display: inline-flex; align-items: center; gap: 6px; height: 28px; margin: 8px 0 0; padding: 0 10px; border: 0; border-radius: var(--r-sm); background: var(--wl-raised); box-shadow: none; color: var(--wl-text); font-size: 12px; cursor: pointer; }
.wt-ws-code-copy-rules .wt-glyph, .wt-ws-code-copy-rules svg { width: 13px; height: 13px; }
.wt-ws-code-tool .wt-glyph { width: 14px; height: 14px; }
.wt-ws-code-drawer { animation: wl-fade var(--wl-short) var(--wl-ease-out); }
.wt-ws-code-drawer[hidden] { display: none; }
.wt-ws-code-guide { display: grid; grid-template-columns: max-content 1fr; gap: 7px 14px; margin: 0; padding: 12px 14px; font-size: 12px; line-height: 1.45; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); }
.wt-ws-code-guide dt { margin: 0; }
.wt-ws-code-guide dd { margin: 0; color: var(--wl-text-2); }
.wt-ws-code-guide code { font-size: 11.5px; white-space: pre; color: var(--wl-text); background: none; padding: 0; }
.wt-ws-code-kinds { display: flex; flex-wrap: wrap; gap: 4px 8px; }
.wt-ws-code-kinds code { color: var(--wl-text-2) !important; }
.wt-ws textarea.wt-ws-code-editor { flex: 1 0 260px; width: 100%; resize: none; padding: 12px 14px; font: 12px/1.65 var(--wl-font-mono); tab-size: 2; white-space: pre; overflow: auto; background: var(--wl-inset); }
.wt-ws .wt-ws-code-error { margin: 0; font-size: 12px; white-space: pre-wrap; }
.wt-ws .wt-ws-code-error:empty { display: none; }
.wt-ws-code-notes { display: flex; flex-direction: column; gap: 4px; }
.wt-ws-code-notes:empty { display: none; }
.wt-ws-code-notes .wt-ws-callout { margin: 0; }
/* Another AI, in the drawer (D-035) */
.wt-ws-code-ai { display: flex; flex-direction: column; gap: 8px; padding: 12px; background: var(--wl-bg); border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-ws-code-ai-row { display: flex; gap: 8px; }
.wt-ws input.wt-ws-code-ai-want { flex: 1; min-width: 0; height: 30px; font-size: 12.5px; }
.wt-ws-code-ai-row button { flex-shrink: 0; height: 30px; gap: 6px; font-size: 12px; }
.wt-ws-code-ai-row .wt-glyph { width: 14px; height: 14px; }
.wt-ws-code-ai .wt-ws-hint { margin: 0; }
.wt-ws-code-ai-result { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; border-top: 1px solid var(--wl-line); }
.wt-ws-code-ai-result[hidden] { display: none; }
.wt-ws-code-ai-done { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.wt-ws-code-ai-done .wt-glyph { width: 14px; height: 14px; color: var(--wl-success); }
.wt-ws-code-ai-done .wt-icon-button { margin-left: auto; }
.wt-ws-ai-notes { margin: 0; padding-left: 18px; font-size: 12.5px; line-height: 1.6; }
@media (max-width: 520px) { .wt-ws-code-ai-row { flex-direction: column; } .wt-surface .wt-ws-code-tools .wt-ws-code-tool:not(.wt-icon-button) > span:not(.wt-glyph) { display: none; } .wt-surface .wt-ws-code-tools .wt-ws-code-tool { width: 30px; padding: 0; justify-content: center; } }
.wt-ws-callout.is-warning { flex-direction: row; align-items: flex-start; gap: 8px; margin: 2px 0 8px; font-size: 12px; line-height: 1.5; color: var(--wl-text); background: color-mix(in srgb, var(--wl-warning) 12%, transparent); }
.wt-ws-callout.is-warning .wt-glyph { margin-top: 2px; flex-shrink: 0; color: var(--wl-warning); }
/* Kinds by group */
.wt-ws-presets { display: flex; flex-direction: column; gap: 6px; }
.wt-ws-presets.is-wide { margin: 0 0 12px; }
.wt-ws-presets-group { margin-top: 6px; font-size: 11px; font-weight: 600; color: var(--wl-text-3); }
/* Field settings */
.wt-ws-field-chevron { width: 13px !important; height: 13px !important; color: var(--wl-text-3) !important; }
.wt-ws-field-detail { margin: 2px 0 10px 14px; padding: 0 8px 10px 12px; border-left: 2px solid var(--wl-selection); }
.wt-surface .wt-ws-style-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; height: auto; padding: 0; font-size: 12px; color: var(--wl-text); background: transparent; }
.wt-ws-style-link .wt-glyph { width: 14px; height: 14px; }
.wt-ws-pair.is-three { grid-template-columns: 1fr 1fr 1fr; }
.wt-ws-options { display: flex; flex-direction: column; gap: 6px; }
/* Each option: its colour, name and remove on one line; emoji and points below. */
/* An option on one line, as a bond is: its colour, its name, its emoji and points, remove. */
.wt-ws-option { display: grid; grid-template-columns: 28px minmax(0, 1fr) 52px 44px 26px; grid-template-areas: "colour name emoji points remove"; gap: 5px; align-items: center; padding-bottom: 6px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-option-colour { grid-area: colour; }
.wt-ws-option-name { grid-area: name; }
.wt-ws-option-emoji { grid-area: emoji; }
.wt-ws-option-points { grid-area: points; }
.wt-ws-option > .wt-icon-button { grid-area: remove; }
.wt-ws-option input { min-width: 0; height: 28px; padding: 2px 6px; font-size: 12px; }
.wt-surface .wt-ws-option-colour { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; background: transparent; border: 1px solid var(--wl-line); border-radius: var(--r-sm); }
.wt-ws-option .wt-icon-button { width: 26px; height: 26px; }
.wt-surface .wt-ws-option-add { align-self: flex-start; height: 28px; padding: 0 8px; gap: 6px; font-size: 12px; background: transparent; color: var(--wl-text-2); }
.wt-surface .wt-ws-option-add:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-ws-option-add .wt-glyph { width: 14px; height: 14px; }
.wt-ws-swatch { display: block; flex-shrink: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--wv-c, transparent); border: 1px solid color-mix(in srgb, var(--wv-c, var(--wl-text-3)) 70%, transparent); }
.wt-ws-swatch[data-colour=""] { background: repeating-linear-gradient(135deg, transparent 0 3px, var(--wl-line-strong) 3px 4px); }
.wt-ws-swatch[data-colour=accent] { --wv-c: var(--interactive-accent); }
.wt-ws-formula-result { margin: 0; padding: 6px 8px; font: 12px var(--wl-font-mono); border-radius: var(--r-sm); background: var(--wl-raised); color: var(--wl-text); }
.wt-ws-formula-result.is-error { font-family: var(--wl-font-ui); color: var(--wl-danger); background: color-mix(in srgb, var(--wl-danger) 10%, transparent); }
.wt-ws-formula-result.is-empty { font-family: var(--wl-font-ui); color: var(--wl-text-2); }
.wt-ws-tokens { display: flex; flex-wrap: wrap; gap: 4px; }
.wt-surface .wt-ws-token { height: 24px; padding: 0 9px; font-size: 11.5px; background: var(--wl-raised); color: var(--wl-text); border-radius: var(--r-md); }
.wt-surface .wt-ws-token.is-function { font-family: var(--wl-font-mono); color: var(--wl-text-2); }
.wt-ws-choice-chips, .wt-choice-input { display: flex; flex-wrap: wrap; gap: 5px; }
.wt-surface .wt-ws-choice-chip, .wt-surface .wt-choice-chip { height: 26px; padding: 0 10px; font-size: 12px; border-radius: var(--r-lg); background: transparent; border: 1px solid var(--wl-line); color: var(--wl-text-2); box-shadow: none; }
.wt-surface .wt-ws-choice-chip[aria-pressed="true"], .wt-surface .wt-choice-chip[aria-pressed="true"] { border-color: var(--wv-c, var(--wl-selection)); color: var(--wl-text); background: color-mix(in srgb, var(--wv-c, var(--wl-selection)) 12%, transparent); }
/* Menus: search, notes and colour swatches */
.wt-ws-menu-search { display: block; width: calc(100% - 4px); height: 30px; margin: 2px 2px 4px; font-size: 12.5px; }
.wt-ws-menu-item > .wt-ws-swatch { width: 14px; height: 14px; }
/* A file's page: saved state, and the Edit form's controls by kind */
.wt-page-status { margin-inline-start: auto; font-size: 12px; color: var(--wl-text-3); white-space: nowrap; }
.wt-page-status:empty { display: none; }
.wt-pagebar .wt-page-status:not(:empty) + .wt-view-toggle { margin-inline-start: 0; }
.wt-control.is-static > .wt-muted { font-size: 13px; }
.wt-control.is-static > .wt-static-value { font-size: 13px; color: var(--wl-text); }
.wt-control.is-static > .wt-small { font-size: 11px; font-weight: 400; }
.wt-masked-input { display: flex; align-items: center; gap: 6px; }
.wt-masked-input > input { flex: 1; }
.wt-masked-input > .wt-icon-button[aria-pressed="true"] { color: var(--wl-selection); }
.wt-control.is-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 7px 10px; }
.wt-control.is-pair > .wt-control-name { grid-column: 1 / -1; }
.wt-control.is-pair > label { display: flex; flex-direction: column; gap: 4px; margin: 0; font-size: 11px; }
.wt-rating-input { display: flex; flex-wrap: wrap; gap: 4px; }
.wt-surface .wt-rating-input button { width: 32px; height: 30px; padding: 0; font-size: 12px; background: transparent; border: 1px solid var(--wl-line); color: var(--wl-text-2); box-shadow: none; }
.wt-surface .wt-rating-input button[aria-pressed="true"] { background: var(--wl-accent); border-color: var(--wl-accent); color: var(--wl-on-accent); }
.wt-link-input { display: flex; flex-direction: column; gap: 2px; max-height: 220px; overflow: auto; padding: 4px; border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-link-option { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border-radius: var(--r-sm); font-size: 13px; font-weight: 400; color: var(--wl-text); cursor: pointer; }
.wt-link-option:hover { background: var(--wl-raised); }
.wt-ws-custom-page .wt-widget { min-height: 0; border: 0; }

/* Focal point: the whole picture with the point that stays in view */
.wt-focus { position: relative; width: fit-content; max-width: 100%; margin: 2px 0; line-height: 0; border-radius: var(--r-sm); overflow: hidden; cursor: crosshair; touch-action: none; user-select: none; background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-focus img { display: block; max-width: 100%; max-height: 200px; pointer-events: none; }
.wt-focus.is-empty { width: 100%; aspect-ratio: 4 / 3; max-height: 160px; background: repeating-linear-gradient(135deg, transparent 0 10px, var(--wl-line) 10px 11px), var(--wl-surface); }
.wt-focus-dot { position: absolute; width: 18px; height: 18px; margin: -9px 0 0 -9px; box-sizing: border-box; border: 2px solid var(--wl-text); border-radius: 50%; background: color-mix(in srgb, var(--wl-selection) 55%, transparent); box-shadow: 0 0 0 1px color-mix(in srgb, var(--wl-bg) 45%, transparent), 0 2px 8px color-mix(in srgb, var(--wl-bg) 35%, transparent); outline: none; }
.wt-focus-dot:focus-visible { box-shadow: 0 0 0 1px color-mix(in srgb, var(--wl-bg) 45%, transparent), 0 0 0 4px var(--wl-selection); }
.wt-ws-focus-actions { display: flex; gap: 8px; }
.wt-ws-menu-custom { display: flex; flex-direction: column; gap: 6px; padding: 2px 8px 8px; }
.wt-ws-menu-custom .wt-focus img { max-height: 180px; }
.wt-ws-menu-custom .wt-ws-menu-note { padding: 0; margin: 0; }
/* Your own colour in a colour menu (D-270): the colour box and its #rrggbb, named by the menu's heading. */
.wt-ws-colour.is-bare { position: relative; grid-template-columns: 30px minmax(0, 1fr); }
.wt-ws-colour.is-bare > span:first-child { position: absolute; top: 0; left: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wt-ws-menu-custom .wt-text-button { align-self: flex-start; }
/* Relationships (D-037): bonds in the panel, the menu form, the Edit form and the map */
/* A bond on one line (D-271): its colour, its words, the other side's words, remove. */
.wt-ws-bond { display: grid; grid-template-columns: 28px minmax(0, 1fr) 26px; grid-template-areas: "colour words remove"; gap: 5px; align-items: center; padding-bottom: 6px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-bond-words { grid-area: words; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5px; min-width: 0; }
/* A bond's two words side by side: the option name's grid place is the option row's, not this one's. */
.wt-ws-bond-words > input { grid-area: auto; }
.wt-ws-bond > .wt-icon-button { grid-area: remove; }
.wt-ws-bond input { min-width: 0; height: 28px; padding: 2px 6px; font-size: 12px; }
.wt-ws-bond input.wt-ws-bond-back { color: var(--wl-text-2); }
.wt-ws-bond .wt-icon-button { width: 26px; height: 26px; }
.wt-tie-form { display: flex; flex-direction: column; gap: 8px; padding-top: 2px; }
.wt-tie-form select, .wt-tie-form .wt-tie-note { width: 100%; height: 30px; font-size: 12.5px; }
.wt-tie-past { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 400; color: var(--wl-text); cursor: pointer; }
.wt-tie-past input { margin: 0; }
.wt-ties-input { display: flex; flex-direction: column; gap: 8px; }
.wt-tie-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) auto 28px; grid-template-areas: "how who past remove" "note note note ."; gap: 6px 8px; align-items: center; padding: 8px; border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-tie-row > select:first-child { grid-area: how; }
.wt-tie-row > select:nth-child(2) { grid-area: who; }
.wt-tie-row > .wt-tie-past { grid-area: past; }
.wt-tie-row > .wt-tie-note { grid-area: note; }
.wt-tie-row > .wt-icon-button { grid-area: remove; }
.wt-tie-theirs { margin: 0; font-size: 12px; font-weight: 400; color: var(--wl-text-2); }
.wt-tie-where { color: var(--wl-text-3); }
@container (max-width: 560px) { .wt-tie-row { grid-template-columns: minmax(0, 1fr) 28px; grid-template-areas: "how remove" "who who" "past past" "note note"; } }
/* The map: faces joined by lines in each bond's colour, with the list beside it */
.wt-map { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; container: wt-map / inline-size; }
.wt-pagebar .wt-map-tools { margin-inline-start: auto; }
.wt-pagebar .wt-page-status:not(:empty) + .wt-map-tools { margin-inline-start: 0; }
.wt-map-tools .wt-icon-button[aria-pressed="true"] { color: var(--wl-selection); }
.wt-map-legend { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 16px; border-bottom: 1px solid var(--wl-line); }
.wt-map-legend[hidden] { display: none; }
.wt-surface .wt-map-chip { display: inline-flex; align-items: center; gap: 7px; flex-shrink: 0; height: 28px; padding: 0 10px; font-size: 12px; color: var(--wl-text); background: transparent; border: 1px solid var(--wl-line); border-radius: var(--r-lg); box-shadow: none; }
.wt-surface .wt-map-chip:hover { background: var(--wl-raised); }
.wt-surface .wt-map-chip[aria-pressed="false"] { color: var(--wl-text-3); border-style: dashed; }
.wt-map-chip small { font-size: 11px; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
.wt-map-chip-line { flex-shrink: 0; width: 16px; height: 0; border-top: 2.5px solid var(--tie, var(--wl-text-2)); border-radius: var(--r-xs); }
.wt-map-chip.is-past .wt-map-chip-line { border-top-style: dashed; border-top-width: 2px; }
.wt-map-chip[aria-pressed="false"] .wt-map-chip-line { opacity: .35; }
.wt-map-main { position: relative; flex: 1; min-height: 0; display: flex; }
.wt-map-stage { position: relative; flex: 1; min-width: 0; min-height: 360px; overflow: hidden; touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; outline: none; background-color: var(--wl-bg); }
.wt-map-stage.is-panning { cursor: grabbing; }
.wt-map-stage:focus-visible { box-shadow: inset 0 0 0 2px var(--wl-selection); }
.wt-map-world { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.wt-map-lines { position: absolute; left: 0; top: 0; width: 1px; height: 1px; overflow: visible; pointer-events: none; }
.wt-map-tie { transition: opacity var(--wl-short) var(--wl-ease); }
.wt-map-line { fill: none; stroke: var(--tie); stroke-width: calc(2.25px * var(--line, 1)); stroke-linecap: round; opacity: .85; transition: stroke-width var(--wl-quick) var(--wl-ease); }
.wt-map-hit { fill: none; stroke: transparent; stroke-width: calc(var(--hit, 14) * 1px); pointer-events: stroke; cursor: pointer; }
.wt-map-arrow { fill: var(--tie); opacity: .9; }
.wt-map-stage.no-arrows .wt-map-arrow { display: none; }
.wt-map-tie.is-past .wt-map-line { stroke-dasharray: 6 5; opacity: .55; }
.wt-map-tie.is-past .wt-map-arrow { opacity: .55; }
.wt-map-tie.is-lit .wt-map-line { stroke-width: calc(3.25px * var(--line, 1)); opacity: 1; }
.wt-map-tie.is-chosen .wt-map-line { stroke-width: calc(4.25px * var(--line, 1)); }
.wt-map-word { font: 600 11px var(--wl-font-ui); fill: color-mix(in srgb, var(--tie) 62%, var(--wl-text)); text-anchor: middle; paint-order: stroke; stroke: var(--wl-bg); stroke-width: 4px; stroke-linejoin: round; pointer-events: auto; cursor: pointer; transition: opacity var(--wl-short) var(--wl-ease), visibility var(--wl-short); }
.wt-map-stage.no-words .wt-map-word, .wt-map-stage.is-quiet .wt-map-word:not(.is-lit), .wt-map-stage.has-focus .wt-map-word:not(.is-lit) { opacity: 0; visibility: hidden; }
.wt-map-stage.has-focus .wt-map-tie:not(.is-lit) { opacity: .12; }
.wt-map-tie.is-dim { opacity: .1; }
.wt-map-faces { position: absolute; left: 0; top: 0; }
.wt-surface .wt-map-node { position: absolute; left: 0; top: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; width: 124px; height: auto; margin: 0; padding: 0; transform: translate(-50%, calc(-28px * var(--size, 1))); background: none; border: 0; box-shadow: none; cursor: pointer; transition: opacity var(--wl-short) var(--wl-ease); }
.wt-surface .wt-map-node:hover, .wt-surface .wt-map-node:focus-visible { background: none; box-shadow: none; outline: none; }
.wt-map-stage.has-focus .wt-map-node:not(.is-lit) { opacity: .28; }
.wt-map-node.is-dim { opacity: .2; }
.wt-map-stage.is-placing, .wt-map-stage.is-placing .wt-map-node { cursor: grabbing; }
.wt-map-face { position: relative; display: grid; place-items: center; flex-shrink: 0; width: 56px; height: 56px; overflow: hidden; border-radius: 50%; background: var(--wl-surface); color: var(--wl-text-2); font: 600 16px var(--wl-font-ui); box-shadow: 0 0 0 2px var(--wl-bg), 0 0 0 3px var(--wl-line-strong), 0 4px 14px color-mix(in srgb, var(--wl-bg) 40%, transparent); }
.wt-map-face img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.wt-map-node .wt-map-face { width: calc(56px * var(--size, 1)); height: calc(56px * var(--size, 1)); font-size: calc(16px * var(--size, 1)); transition: box-shadow var(--wl-quick) var(--wl-ease), transform var(--wl-short) cubic-bezier(.2, .8, .2, 1.4); }
.wt-map-node:hover .wt-map-face { transform: scale(1.07); box-shadow: 0 0 0 2px var(--wl-bg), 0 0 0 4px var(--wl-text-3), 0 6px 16px color-mix(in srgb, var(--wl-bg) 50%, transparent); }
.wt-map-stage.is-placing .wt-map-node.is-lit .wt-map-face { transform: scale(1.1); }
.wt-map-node.has-ring .wt-map-face { box-shadow: 0 0 0 2px var(--wl-bg), 0 0 0 4.5px var(--ring), 0 4px 14px color-mix(in srgb, var(--wl-bg) 40%, transparent); }
.wt-map-node.is-outside .wt-map-face { outline: 1.5px dashed var(--wl-text-3); outline-offset: 4px; }
.wt-map-node.is-selected .wt-map-face, .wt-map-node:focus-visible .wt-map-face { box-shadow: 0 0 0 2px var(--wl-bg), 0 0 0 4.5px var(--wl-selection), 0 6px 18px color-mix(in srgb, var(--wl-bg) 40%, transparent); }
.wt-map-name { max-width: 124px; overflow: hidden; padding: 1px 6px; border-radius: var(--r-sm); font-size: 12.5px; font-weight: 600; line-height: 1.35; color: var(--wl-text); white-space: nowrap; text-overflow: ellipsis; background: color-mix(in srgb, var(--wl-bg) 86%, transparent); }
.wt-map-kind { margin-top: -5px; font-size: 10.5px; color: var(--wl-text-3); }
.wt-map-name, .wt-map-kind { transition: opacity var(--wl-short) var(--wl-ease), visibility var(--wl-short); }
.wt-map-stage.is-far .wt-map-name, .wt-map-stage.is-far .wt-map-kind, .wt-map-stage.is-far .wt-map-word { opacity: 0; visibility: hidden; }
.wt-map-empty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 24px; text-align: center; cursor: auto; }
.wt-map-empty[hidden] { display: none; }
.wt-map-empty h2 { margin: 8px 0 0; font-size: 17px; }
.wt-map-empty p { max-width: 380px; margin: 0 0 12px; }
.wt-map-empty-icon { width: 36px; height: 36px; color: var(--wl-text-3); }
.wt-map-stage.is-empty .wt-map-settings { display: none; }
.wt-map-meta { margin: 0; padding: 6px 16px; font-size: 11.5px; color: var(--wl-text-3); border-top: 1px solid var(--wl-line); }
.wt-map-meta:empty { display: none; }
/* Map settings: filters, groups, display and forces */
/* Zoom and fit in the map's corner (the bar above keeps only the list's switch). */
.wt-map-zoom { position: absolute; right: 10px; bottom: 10px; z-index: 3; display: flex; flex-direction: column; gap: 2px; padding: 3px; cursor: auto; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-md); box-shadow: 0 2px 8px color-mix(in srgb, var(--wl-bg) 30%, transparent); }
.wt-surface .wt-map-zoom .wt-icon-button { width: 28px; height: 28px; color: var(--wl-text-2); }
.wt-surface .wt-map-zoom .wt-icon-button:hover { color: var(--wl-text); }
.wt-map-stage.is-empty .wt-map-zoom { display: none; }
/* The bonds to show and the count, at the top of the settings; a dot on the closed gear while any is hidden. */
.wt-map-set-show { display: flex; flex-direction: column; gap: 8px; padding: 10px 12px 12px; border-bottom: 1px solid var(--wl-line); }
.wt-map-set-label { min-height: 20px; padding-right: 30px; font-size: 12px; font-weight: 600; color: var(--wl-text-2); }
.wt-map-set-show .wt-map-legend { padding: 0; border: 0; gap: 6px; }
.wt-map-set-show .wt-map-meta { padding: 0; border: 0; }
.wt-surface .wt-map-settings:not(.is-open) .wt-map-gear { position: relative; }
.wt-map-settings.is-filtered:not(.is-open) .wt-map-gear::after { content: ""; position: absolute; top: 5px; right: 5px; width: 7px; height: 7px; border-radius: 50%; background: var(--wl-accent); box-shadow: 0 0 0 2px var(--wl-surface); }
.wt-map-settings { position: absolute; top: 10px; right: 10px; z-index: 3; display: flex; flex-direction: column; max-height: calc(100% - 20px); cursor: auto; user-select: text; -webkit-user-select: text; }
.wt-surface .wt-map-gear { width: 32px; height: 32px; color: var(--wl-text-2); background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-md); box-shadow: 0 2px 8px color-mix(in srgb, var(--wl-bg) 30%, transparent); }
.wt-surface .wt-map-gear:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-map-settings.is-open { transform-origin: top right; animation: wt-map-pop .18s cubic-bezier(.2, .8, .2, 1); width: 264px; background: var(--wl-surface); border: 1px solid var(--wl-line); border-radius: var(--r-lg); box-shadow: var(--wl-elev-pop); }
.wt-surface .wt-map-settings.is-open .wt-map-gear { position: absolute; top: 4px; right: 4px; z-index: 1; width: 28px; height: 28px; background: transparent; border: 0; box-shadow: none; }
.wt-map-set-body { overflow: auto; padding: 2px 0 10px; overscroll-behavior: contain; }
.wt-map-set + .wt-map-set { border-top: 1px solid var(--wl-line); }
.wt-map-set > summary { display: flex; align-items: center; gap: 6px; padding: 9px 40px 9px 10px; font-size: 13px; font-weight: 600; color: var(--wl-text); list-style: none; cursor: pointer; }
.wt-map-set > summary::-webkit-details-marker { display: none; }
.wt-map-set > summary:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: -2px; border-radius: var(--r-sm); }
.wt-map-set-chevron { width: 14px; height: 14px; color: var(--wl-text-3); transition: transform var(--wl-quick) var(--wl-ease); }
.wt-map-set-chevron svg { width: 14px; height: 14px; }
.wt-map-set[open] .wt-map-set-chevron { transform: rotate(90deg); }
.wt-map-set-rows { display: flex; flex-direction: column; gap: 11px; padding: 2px 14px 14px 30px; }
.wt-map-set-row { display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--wl-text); cursor: pointer; }
.wt-map-set-slide { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--wl-text); }
.wt-map-set-head { display: flex; justify-content: space-between; gap: 8px; }
.wt-map-set-head output { font-size: 11.5px; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
.wt-map-set-slide input[type="range"] { width: 100%; }
.wt-map input.wt-map-search { width: 100%; height: 30px; font-size: 12.5px; }
.wt-map-set-pick { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--wl-text); }
.wt-map-set-pick select { width: 100%; }
.wt-map-groups { display: flex; flex-direction: column; gap: 5px; margin: 0; padding: 0; list-style: none; font-size: 12px; }
.wt-map-groups[hidden] { display: none; }
.wt-map-groups li { display: flex; align-items: center; gap: 8px; min-width: 0; }
.wt-map-groups li > span:nth-child(2) { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wt-map-groups small { margin-inline-start: auto; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
.wt-map-dot { flex-shrink: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--ring); }
.wt-surface .wt-map-set-button { justify-content: center; gap: 6px; height: 30px; font-size: 12.5px; }
.wt-surface .wt-map-set-reset { justify-content: center; gap: 6px; width: calc(100% - 20px); height: 30px; margin: 6px 10px 0; font-size: 12.5px; color: var(--wl-text-2); background: transparent; box-shadow: none; }
.wt-surface .wt-map-set-reset:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-map-set-button .wt-glyph, .wt-map-set-reset .wt-glyph, .wt-map-back .wt-glyph, .wt-map-open .wt-glyph, .wt-map-remove .wt-glyph { width: 14px; height: 14px; }
/* The list beside the map, and each relationship from both sides */
.wt-map-side { position: relative; display: flex; flex: 0 0 340px; flex-direction: column; min-width: 0; min-height: 0; overflow: hidden; background: var(--wl-surface); border-left: 1px solid var(--wl-line); transition: flex-basis var(--wl-long) cubic-bezier(.2, .8, .2, 1), opacity var(--wl-short) var(--wl-ease), visibility 0s; }
.wt-map-side.is-hidden { flex-basis: 0; opacity: 0; visibility: hidden; border-left-width: 0; transition: flex-basis var(--wl-long) cubic-bezier(.2, .8, .2, 1), opacity var(--wl-short) var(--wl-ease), visibility 0s linear var(--wl-long); }
.wt-map-side-head, .wt-map-side-body { min-width: 280px; }
.wt-surface .wt-map-collapse { flex-shrink: 0; width: 28px; height: 28px; margin-inline-end: -4px; color: var(--wl-text-2); }
.wt-map-side .wt-map-face { background: var(--wl-line); }
/* The tab that brings the list back */
.wt-surface .wt-map-reopen { position: absolute; top: 50%; right: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; gap: 8px; width: 34px; height: auto; margin: 0; padding: 12px 0; translate: 0 -50%; font-size: 12px; font-weight: 500; color: var(--wl-text-2); background: var(--wl-surface); border: 1px solid var(--wl-line); border-right: 0; border-radius: var(--r-md) 0 0 var(--r-md); box-shadow: -4px 0 14px color-mix(in srgb, var(--wl-bg) 30%, transparent); cursor: pointer; animation: wt-map-pop var(--wl-short) var(--wl-ease-scene); }
.wt-surface .wt-map-reopen:hover { color: var(--wl-text); }
.wt-surface .wt-map-reopen:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 2px; }
.wt-map-reopen[hidden] { display: none; }
.wt-map-reopen .wt-glyph { width: 15px; height: 15px; }
.wt-map-reopen > span:not(.wt-glyph) { writing-mode: vertical-rl; }
.wt-map-reopen small { font-size: 11px; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
@keyframes wt-map-pop { from { opacity: 0; transform: scale(.94); } }
.wt-map-side-head { position: relative; display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 12px 8px 16px; border-bottom: 1px solid var(--wl-line); }
.wt-surface .wt-map-handle { display: none; }
.wt-map-side-title { display: flex; flex: 1; align-items: baseline; gap: 8px; min-width: 0; }
.wt-map-side-title h3 { margin: 0; font-size: 14px; font-weight: 600; }
.wt-map-side-title small { font-size: 12px; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
.wt-map select.wt-map-sort { height: 28px; font-size: 12px; }
.wt-map-side-body { flex: 1; min-height: 0; overflow: auto; padding: 8px; overscroll-behavior: contain; }
.wt-map-side-none { margin: 16px 10px; font-size: 13px; color: var(--wl-text-2); }
.wt-map-side-sub { margin: 6px 10px 6px; font-size: 12px; font-weight: 600; color: var(--wl-text-3); }
.wt-map-rows { display: flex; flex-direction: column; gap: 2px; margin: 0; padding: 0; list-style: none; }
.wt-surface .wt-map-row { display: flex; align-items: center; justify-content: flex-start; gap: 12px; width: 100%; height: auto; min-height: 56px; padding: 8px 10px; font-weight: 400; color: var(--wl-text); text-align: left; white-space: normal; background: transparent; border: 0; border-radius: var(--r-md); box-shadow: none; cursor: pointer; }
.wt-surface .wt-map-row:hover, .wt-surface .wt-map-row.is-lit { background: var(--wl-raised); }
.wt-surface .wt-map-row:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: -2px; }
.wt-map-pair { display: flex; flex-shrink: 0; }
.wt-map-pair .wt-map-face { width: 40px; height: 40px; font-size: 13px; box-shadow: 0 0 0 2px var(--wl-surface); }
.wt-map-pair .wt-map-face + .wt-map-face { margin-inline-start: -14px; }
.wt-map-row-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.wt-map-row-name { font-size: 13.5px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.wt-map-row.is-past .wt-map-row-name { color: var(--wl-text-2); }
.wt-map-row-bonds { font-size: 12.5px; line-height: 1.35; color: var(--wl-text-3); }
.wt-map-row-bond { color: color-mix(in srgb, var(--tie) 65%, var(--wl-text-2)); }
.wt-map-row-bond.is-past { opacity: .7; }
.wt-surface .wt-map-back { gap: 6px; height: 30px; margin-inline-start: -6px; padding: 0 10px 0 6px; font-size: 13px; color: var(--wl-text-2); background: transparent; box-shadow: none; }
.wt-surface .wt-map-back:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-map-who { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px 16px; text-align: center; }
.wt-map-face.is-big { width: 72px; height: 72px; font-size: 22px; }
.wt-map-who-text { display: flex; flex-direction: column; gap: 2px; }
.wt-map-who-text h3 { margin: 0; font-size: 16px; }
.wt-map-who-text small { font-size: 12px; color: var(--wl-text-3); }
.wt-surface .wt-map-open { justify-content: center; gap: 6px; }
.wt-map-duo { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: start; gap: 4px; padding: 10px 2px 14px; }
.wt-surface .wt-map-duo-who { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; height: auto; padding: 6px 4px; white-space: normal; background: transparent; border-radius: var(--r-md); box-shadow: none; }
.wt-surface .wt-map-duo-who:hover { background: var(--wl-raised); }
.wt-map-duo-who strong { font-size: 13px; text-align: center; overflow-wrap: anywhere; }
.wt-map-duo-link { display: flex; flex-direction: column; align-items: center; gap: 8px; min-width: 0; padding-top: 26px; }
.wt-map-duo-line { width: 56px; height: 0; border-top: 2.5px solid var(--tie); border-radius: var(--r-xs); }
.wt-map-duo-line.is-past { border-top-style: dashed; }
.wt-map select.wt-map-bond { max-width: 124px; height: 28px; font-size: 12px; }
.wt-surface .wt-map-bond-tab { max-width: 124px; height: 26px; padding: 0 10px; overflow: hidden; font-size: 12px; font-weight: 500; color: color-mix(in srgb, var(--tie) 65%, var(--wl-text-2)); white-space: nowrap; text-overflow: ellipsis; background: transparent; border: 1px solid var(--wl-line); border-radius: var(--r-sm); box-shadow: none; }
.wt-surface .wt-map-bond-tab:hover { background: var(--wl-raised); }
.wt-surface .wt-map-bond-tab.is-past { opacity: .75; }
.wt-map-shared, .wt-map-view { display: flex; flex-direction: column; gap: 12px; margin: 0 2px 10px; padding: 12px; background: var(--wl-bg); border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-map-view-head { display: flex; align-items: center; gap: 10px; }
.wt-map-view-head .wt-map-face { width: 28px; height: 28px; font-size: 10px; box-shadow: none; }
.wt-map-view-head h4 { margin: 0; font-size: 13px; font-weight: 600; }
.wt-map-feel { display: flex; flex-direction: column; gap: 6px; }
.wt-map-feel-top { display: flex; align-items: center; gap: 8px; min-height: 24px; }
.wt-map-feel-label { font-size: 12px; color: var(--wl-text-3); }
.wt-map-feel-said { margin-inline-start: auto; font-size: 12.5px; font-weight: 600; }
.wt-map-feel.is-unset .wt-map-feel-said { font-weight: 400; color: var(--wl-text-3); }
.wt-surface .wt-map-feel-clear { width: 24px; height: 24px; margin-inline-end: -4px; }
.wt-surface .wt-map-feel-clear[hidden] { display: none; }
.wt-map input[type="range"].wt-map-range { --fill: var(--wl-success); width: 100%; height: 6px; margin: 6px 0; background: linear-gradient(to right, var(--wl-line) min(var(--at, 50%), 50%), var(--fill) min(var(--at, 50%), 50%) max(var(--at, 50%), 50%), var(--wl-line) max(var(--at, 50%), 50%)); border-radius: var(--r-xs); cursor: pointer; }
.wt-map input[type="range"].wt-map-range[data-sign="low"] { --fill: var(--wl-danger); }
.wt-map input[type="range"].wt-map-range::-webkit-slider-thumb { width: 18px; height: 18px; top: 0; margin-top: -6px; border-radius: 50%; background: var(--wl-bg); border: 2px solid var(--fill); cursor: pointer; }
.wt-map .wt-map-feel.is-unset input[type="range"].wt-map-range::-webkit-slider-thumb { border-color: var(--wl-text-3); }
.wt-map-feel-ends { display: flex; justify-content: space-between; font-size: 11px; color: var(--wl-text-3); }
.wt-map-note { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--wl-text-3); }
.wt-map .wt-map-note textarea { width: 100%; min-height: 54px; padding: 6px 8px; font-size: 13px; line-height: 1.45; color: var(--wl-text); resize: none; }
.wt-map-tie-foot { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 2px 12px; }
.wt-surface .wt-map-remove { gap: 6px; margin-inline-start: auto; color: var(--wl-danger); background: transparent; box-shadow: none; }
.wt-surface .wt-map-remove:hover { background: color-mix(in srgb, var(--wl-danger) 10%, transparent); }
.wt-surface .wt-map-remove.is-sure { color: var(--wl-bg); background: var(--wl-danger); }
/* Tablet: a narrower list. Phone: the list is a sheet along the bottom */
@container wt-map (max-width: 900px) { .wt-map-side { flex-basis: 300px; } }
@container wt-map (max-width: 640px) {
  .wt-map-zoom { bottom: 64px; }
  .wt-map-stage { min-height: 300px; }
  .wt-map-side { position: absolute; left: 0; right: 0; bottom: 0; z-index: 4; height: 62%; border-left: 0; border-top: 1px solid var(--wl-line); border-radius: var(--r-xl) var(--r-xl) 0 0; box-shadow: var(--wl-elev-pop); transition: transform var(--wl-long) cubic-bezier(.2, .8, .2, 1); }
  .wt-map-side[data-sheet="peek"] { transform: translateY(calc(100% - 52px)); }
  .wt-map-side.is-hidden { opacity: 1; transform: translateY(100%); transition: transform var(--wl-long) cubic-bezier(.2, .8, .2, 1), visibility 0s linear var(--wl-long); }
  .wt-surface .wt-map-reopen { top: auto; right: auto; bottom: 12px; left: 50%; flex-direction: row; width: auto; height: 34px; padding: 0 14px; translate: -50% 0; border: 1px solid var(--wl-line); border-radius: var(--r-pill); box-shadow: var(--wl-elev-pop); }
  .wt-map-reopen > span:not(.wt-glyph) { writing-mode: horizontal-tb; }
  .wt-map-side-head { min-height: 52px; padding-top: 14px; }
  .wt-map-side[data-sheet="peek"] .wt-map-side-head { cursor: pointer; }
  .wt-surface .wt-map-handle { position: absolute; top: 0; left: 50%; display: block; width: 72px; height: 16px; margin: 0; padding: 0; translate: -50% 0; background: transparent; border: 0; box-shadow: none; }
  .wt-map-handle::before { content: ""; display: block; width: 36px; height: 4px; margin: 6px auto 0; border-radius: var(--r-xs); background: var(--wl-line-strong); }
  .wt-map-settings { max-height: calc(100% - 72px); }
  .wt-map-settings.is-open { width: min(264px, calc(100% - 20px)); }
}
@media (prefers-reduced-motion: reduce) { .wt-map-tie, .wt-map-node, .wt-map-face, .wt-map-node .wt-map-face, .wt-map-line, .wt-map-word, .wt-map-name, .wt-map-kind, .wt-map-side, .wt-map-set-chevron { transition: none; } .wt-map-reopen, .wt-map-settings.is-open { animation: none; } }

/* ── Boris: a small dark cube in the workspace's corner, and its chat panel ──
   Both live in the workspace row (.horizontal-main-container, or the own window's row under its
   bar), so they never cover the
   Projects page or the top bar. Docked, the panel sits beside the workspace and its left
   edge sets the width; floating, it is a window over the workspace. Its top bar drags it
   between the two. The row is not made a positioned box (the rail's toggle is placed
   against the window), so the cube and the floating panel are placed on the window.
   (Classes keep the name Orbis.) */
body { --wt-orbis-width: 360px; }

/* Boris: Orbis as a cube. Light blue like water, with a slow sheen flowing across it; one shape
   at three sizes. It slowly changes shape, blinks and looks at the pointer. */
/* Boris's water: ice with a little mint, lighter at the top and deeper at the foot. */
.wt-orbis-blob, .wt-orbis-orb, .wt-orb-spark { --wt-water: color-mix(in srgb, var(--wl-selection) 62%, var(--wl-success)); --wt-water-hi: color-mix(in srgb, var(--wl-text) 72%, var(--wt-water)); --wt-water-mid: color-mix(in srgb, var(--wt-water) 80%, var(--wl-bg)); --wt-water-deep: color-mix(in srgb, var(--wt-water) 62%, var(--wl-bg)); }
.wt-orbis-blob { --size: 40px; position: relative; display: grid; place-items: center; flex-shrink: 0; width: var(--size); height: var(--size); font-size: var(--size); border-radius: 34% 38% 36% 32% / 36% 32% 38% 34%; overflow: hidden; background: radial-gradient(circle at 32% 26%, var(--wt-water-hi), var(--wt-water) 38%, var(--wt-water-mid) 72%, var(--wt-water-deep)); box-shadow: inset 0 .07em .1em color-mix(in srgb, var(--wl-text) 69%, transparent), inset 0 -.09em .16em color-mix(in srgb, var(--wt-water-deep) 45%, transparent), 0 .1em .28em color-mix(in srgb, var(--wl-bg) 45%, transparent); animation: wt-orbis-breathe 7s ease-in-out infinite; }
/* The water: soft light drifting slowly over the surface. The light is a layer larger than the blob that slides under
   its rounded edge (moved, not repainted, so it costs nothing while it drifts); the blob's shape breathes the same way.
   Only while Boris thinks do the corners themselves change, for a moment. */
.wt-orbis-blob::before { content: ""; position: absolute; left: 0; top: 0; width: 180%; height: 180%; background: radial-gradient(45% 32% at 30% 28%, color-mix(in srgb, var(--wl-text) 40%, transparent), transparent 70%), radial-gradient(40% 28% at 72% 74%, color-mix(in srgb, var(--wl-text) 20%, transparent), transparent 70%); animation: wt-boris-flow 9s ease-in-out infinite alternate; pointer-events: none; }
.wt-orbis-blob.is-large { --size: 60px; margin-bottom: 4px; box-shadow: inset 0 .07em .1em color-mix(in srgb, var(--wl-text) 69%, transparent), inset 0 -.09em .16em color-mix(in srgb, var(--wt-water-deep) 45%, transparent), 0 0 52px 14px color-mix(in srgb, var(--wt-water) 25%, transparent); animation: wt-orbis-breathe 7s ease-in-out infinite, wt-orbis-bob 4.4s ease-in-out infinite; }
.wt-orbis-blob.is-tiny { --size: 24px; margin-top: 1px; }
.wt-orbis-blob.is-thinking { animation: wt-orbis-morph 1.6s ease-in-out infinite, wt-orbis-think 1.2s ease-in-out infinite; }
.wt-orb-face { position: relative; z-index: 1; display: flex; gap: .15em; transform: translate(var(--wt-eye-x, 0px), calc(var(--wt-eye-y, 0px) + .02em)); transition: transform var(--wl-quick) var(--wl-ease-out); }
.wt-orb-face i { position: relative; width: .13em; height: .19em; border-radius: 50%; background: radial-gradient(circle at 50% 65%, color-mix(in srgb, var(--wl-bg) 88%, var(--wl-selection)), var(--wl-bg) 70%); box-shadow: 0 .012em .02em color-mix(in srgb, var(--wl-text) 35%, transparent); animation: wt-orbis-blink 5.6s infinite; }
.wt-orb-face i::before, .wt-orb-face i::after { content: ""; position: absolute; border-radius: 50%; background: var(--wl-text); }
.wt-orb-face i::before { left: 20%; top: 14%; width: 44%; height: 32%; }
.wt-orb-face i::after { right: 18%; bottom: 18%; width: 20%; height: 14%; opacity: .7; }
.wt-orbis-blob.is-tiny .wt-orb-face i { animation-delay: -2.3s; }
/* Clicked: a happy squint and a little hop (the corner button squints while pressed). */
.wt-orbis-blob.is-booped { animation: wt-orbis-breathe 7s ease-in-out infinite, wt-orbis-hop .6s cubic-bezier(.3,1.4,.5,1); }
.wt-orbis-blob.is-booped .wt-orb-face i { animation: wt-orbis-squint .7s ease-out; }
.wt-orbis-orb:active .wt-orb-face i { animation: none; transform: scaleY(.35); }

/* The corner button: floats a little, glows softly, and squishes when pointed at. */
/* Design's Look (D-278): the card's four colours as swatches on one line, each named under it, and a reset beside
   them once one is chosen. The title face is a box like the panel's other picks; its menu shows each in itself. */
.wt-ws-swatches { display: grid; grid-template-columns: repeat(4, minmax(max-content, 1fr)) auto; gap: 6px; align-items: start; margin-bottom: 2px; }
.wt-ws-swatch-pick { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; font-size: 11px; color: var(--wl-text-2); cursor: pointer; }
.wt-ws-swatch-pick > span { max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
body.wb-shell .wt-ws-swatch-pick input[type="color"] { width: 100%; height: 28px; padding: 2px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-bg); cursor: pointer; transition: border-color var(--wl-quick) var(--wl-ease); }
body.wb-shell .wt-ws-swatch-pick:hover input[type="color"] { border-color: var(--wl-line-strong); }
.wt-ws-swatch-pick input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.wt-ws-swatch-pick input[type="color"]::-webkit-color-swatch { border: 0; border-radius: var(--r-xs); }
body.wb-shell .wt-ws-swatch-reset { width: 28px; height: 28px; }
.wt-ws-menu-face { line-height: 1.25; font-synthesis: none; }
/* While a type's Page view shows, Boris's panel script moves the orb left of the editor's settings (--wt-orb-right, D-270),
   or above them when they rise from the bottom (--wt-orb-bottom). */
body button.wt-orbis-orb { position: fixed; right: var(--wt-orb-right, 20px); bottom: var(--wt-orb-bottom, 30px); z-index: 30; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 30%; background: transparent; box-shadow: none; cursor: pointer; animation: wt-orbis-float 4.4s ease-in-out infinite; transition: opacity var(--wl-short) var(--wl-ease), scale var(--wl-short) cubic-bezier(.2,.8,.2,1), visibility 0s, right var(--wl-short) var(--wl-ease), bottom var(--wl-short) var(--wl-ease); }
body button.wt-orbis-orb::before { content: ""; position: absolute; inset: -14px; border-radius: 34%; background: radial-gradient(circle, color-mix(in srgb, var(--wt-water) 40%, transparent), transparent 66%); animation: wt-orbis-glow 4.4s ease-in-out infinite; pointer-events: none; }
body button.wt-orbis-orb:hover { background: transparent; }
.wt-orbis-orb:hover .wt-orbis-blob { animation: wt-orbis-breathe 7s ease-in-out infinite, wt-orbis-squish .6s cubic-bezier(.3,1.5,.5,1); }
.wt-orbis-orb:active .wt-orbis-blob { scale: .92; }
body button.wt-orbis-orb .wt-orbis-blob { box-shadow: inset 0 .07em .1em color-mix(in srgb, var(--wl-text) 69%, transparent), inset 0 -.09em .16em color-mix(in srgb, var(--wt-water-deep) 45%, transparent), 0 0 22px 4px color-mix(in srgb, var(--wt-water) 25%, transparent); }
.wt-orb-spark { position: absolute; right: 0; top: -3px; font-size: 11px; line-height: 1; color: var(--wt-water); text-shadow: 0 0 6px var(--wt-water-mid); animation: wt-orbis-twinkle 3.2s ease-in-out infinite; pointer-events: none; }
body.wt-orbis-active button.wt-orbis-orb { opacity: 0; scale: .6; visibility: hidden; pointer-events: none; transition: opacity var(--wl-quick) var(--wl-ease), scale var(--wl-quick) var(--wl-ease), visibility 0s var(--wl-quick); }
/* Boris belongs to a project: he is not over the Projects page or a game (the inherited shell
   hides the whole workspace row then; the own window draws those pages over it). In a game he
   sits in the game's own panel instead (embedOrbis marks him .is-embedded), and shows there. */
body:is(.wb-projects-open, .wb-game-open) :is(button.wt-orbis-orb, .wt-orbis-panel:not(.is-embedded), .wt-orbis-dock-hint) { visibility: hidden; }
/* A map keeps its help button in the bottom-right corner, so Boris sits a little higher there. */
/* The inherited shell's canvas tabs only. :not(.wl-own) comes before :has() so the own window never asks it: a :has()
   on body made Chrome look through the whole page whenever anything it reads changed (a class, a hidden, a new turn). */
body:not(.wl-own):has(.mod-root .workspace-tab-header.is-active[data-type="canvas"]) button.wt-orbis-orb { bottom: 72px; }

/* The panel. */
.wt-orbis-panel { --no-tooltip: true; position: relative; z-index: 20; display: flex; flex: 0 0 var(--wt-orbis-width); width: var(--wt-orbis-width); min-width: 0; overflow: hidden; background: var(--wl-bg); border-inline-start: 1px solid var(--wl-line); color: var(--wl-text); }
.wt-orbis-inner { position: relative; display: flex; flex-direction: column; flex-shrink: 0; width: var(--wt-orbis-width); height: 100%; min-height: 0; animation: wt-orbis-slide .22s cubic-bezier(.2,.8,.2,1); }
.wt-orbis-panel.is-closing { pointer-events: none; }
.wt-orbis-panel.is-closing .wt-orbis-inner { opacity: 0; translate: 10px 0; transition: opacity var(--wl-quick) var(--wl-ease), translate var(--wl-quick) var(--wl-ease); }
.wt-orbis-panel.is-floating { position: fixed; z-index: 40; flex: none; min-width: 320px; min-height: 360px; max-width: calc(100vw - 16px); max-height: calc(100vh - var(--wt-orbis-top, 60px) - 16px); border: 1px solid var(--wl-line); border-radius: var(--r-xl); box-shadow: var(--wl-elev-pop); resize: both; }
.wt-orbis-panel.is-floating .wt-orbis-inner { width: 100%; animation: wt-orbis-pop .18s cubic-bezier(.2,.8,.2,1); }
.wt-orbis-panel.is-floating.is-closing .wt-orbis-inner { translate: 0 6px; }
.wt-orbis-panel.is-floating.is-closing { opacity: 0; transition: opacity var(--wl-quick) var(--wl-ease); }
/* Docked, the left edge sets the width, as the side panels' edges do. */
/* Inside the panel's edge (the panel clips what sticks out). */
.wt-orbis-edge { position: absolute; top: 0; bottom: 0; left: 0; z-index: 3; width: 6px; cursor: col-resize; --no-tooltip: true; }
.wt-orbis-edge::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 2px; background: transparent; transition: background-color var(--wl-quick) var(--wl-ease); }
.wt-orbis-edge:hover::after, .wt-orbis-edge:focus-visible::after, .wt-orbis-panel.is-resizing .wt-orbis-edge::after { background: var(--wl-selection); }
.wt-orbis-edge:focus-visible { outline: none; }
.wt-orbis-panel.is-floating .wt-orbis-edge { display: none; }
/* boris-panel.mjs marks the body while the panel is resized, rather than a :has() on body (see the orb above). */
.wt-orbis-panel.is-resizing, body.wt-orbis-resizing { cursor: col-resize; user-select: none; }
/* While the panel is dragged, the right edge shows where it docks. */
.wt-orbis-dock-hint { position: fixed; z-index: 35; border: 1px dashed transparent; border-radius: var(--r-md); background: transparent; pointer-events: none; transition: background-color var(--wl-quick) var(--wl-ease), border-color var(--wl-quick) var(--wl-ease); }
.wt-orbis-dock-hint.is-on { border-color: color-mix(in srgb, var(--wl-selection) 55%, transparent); background: color-mix(in srgb, var(--wl-selection) 8%, transparent); }
.wt-orbis-panel.is-dragging { user-select: none; box-shadow: var(--wl-elev-pop); }

/* Top bar: chat tabs, then New chat, History, Position and Close. */
.wt-orbis-bar { display: flex; align-items: center; gap: 6px; flex-shrink: 0; height: 44px; padding: 0 6px 0 10px; border-bottom: 1px solid var(--wl-line); }
.wt-orbis-grip { display: inline-flex; flex-shrink: 0; color: var(--wl-text-3); margin-inline: -4px -2px; }
.wt-orbis-grip svg { width: 14px; height: 14px; }
.wt-orbis-bar { cursor: grab; }
.wt-orbis-panel.is-dragging .wt-orbis-bar { cursor: grabbing; }
.wt-orbis-tabs { display: flex; align-items: center; gap: 2px; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.wt-orbis-tabs::-webkit-scrollbar { display: none; }
.wt-orbis-tab { display: flex; align-items: center; flex: 0 1 auto; min-width: 56px; max-width: 148px; height: 28px; border-radius: var(--r-md); color: var(--wl-text-2); transition: background-color var(--wl-quick), color var(--wl-quick); }
.wt-orbis-tab:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-tab.is-active { color: var(--wl-text); background: var(--wl-raised); }
body .wt-orbis-tab button.wt-orbis-tab-title { flex: 1; justify-content: flex-start; min-width: 0; overflow: hidden; height: 28px; padding: 0 10px; border: 0; background: transparent; box-shadow: none; color: inherit; font-size: 12.5px; font-weight: 500; cursor: pointer; }
.wt-orbis-tab-title span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-tab:has(.wt-orbis-tab-close) button.wt-orbis-tab-title { padding-inline-end: 2px; }
body .wt-orbis-tab button.wt-orbis-tab-close { width: 20px; height: 20px; margin-inline-end: 4px; border-radius: var(--r-sm); opacity: 0; }
.wt-orbis-tab:hover .wt-orbis-tab-close, .wt-orbis-tab.is-active .wt-orbis-tab-close, .wt-orbis-tab-close:focus-visible { opacity: 1; }
.wt-orbis-tab-close .wt-glyph svg { width: 12px; height: 12px; }
.wt-orbis-tools { display: flex; align-items: center; gap: 1px; flex-shrink: 0; }
.wt-orbis-panel .wt-icon-button { --no-tooltip: false; }
.wt-orbis-panel .wt-icon-button[aria-expanded="true"] { background: var(--wl-raised); color: var(--wl-text); }

/* The conversation. */
.wt-orbis-chat { display: flex; flex-direction: column; flex: 1; min-height: 0; overflow-y: auto; padding: 18px 16px 12px; }
.wt-orbis-welcome { display: flex; flex-direction: column; align-items: center; margin: auto 0; padding: 8px 0; text-align: center; animation: wt-orbis-rise .26s cubic-bezier(.2,.8,.2,1); }
.wt-orbis-welcome h2 { margin-top: 14px; } /* its face and size: boris-panel.css (a panel title) */
.wt-orbis-panel p.wt-orbis-lead { max-width: 270px; margin: 6px 0 20px; font-size: 12.5px; line-height: 1.5; color: var(--wl-text-2); }
.wt-orbis-welcome .wt-orbis-other { margin: 16px 0 0; font-size: 11.5px; }
.wt-orbis-thread { display: flex; flex-direction: column; gap: 16px; }
.wt-orbis-msg { font-size: 13px; line-height: 1.55; }
.wt-orbis-msg.is-new { animation: wt-orbis-rise .22s cubic-bezier(.2,.8,.2,1); }
.wt-orbis-msg.is-you { align-self: flex-end; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; max-width: 85%; }
.wt-orbis-bubble { position: relative; padding: 8px 12px; border-radius: var(--r-lg) var(--r-lg) var(--r-xs) var(--r-lg); background: color-mix(in srgb, var(--wl-accent) 16%, var(--wl-surface)); white-space: pre-wrap; overflow-wrap: anywhere; }
.wt-orbis-msg.is-orbis { display: flex; align-items: flex-start; gap: 10px; }
.wt-orbis-reply { flex: 1; min-width: 0; padding-top: 2px; overflow-wrap: anywhere; }
.wt-orbis-panel .wt-orbis-reply > p { margin: 0; line-height: 1.55; }
.wt-orbis-card { margin-top: 10px; padding: 12px 14px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-surface); }
.wt-orbis-eyebrow { display: block; font-size: 10.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--wl-text-2); }
.wt-orbis-card strong { display: block; margin-top: 3px; font-size: 14px; font-weight: 600; }
.wt-orbis-panel .wt-orbis-card p { margin: 4px 0 0; font-size: 12px; line-height: 1.5; color: var(--wl-text-2); }
.wt-orbis-panel .wt-orbis-card p.wt-orbis-note, .wt-orbis-panel p.wt-orbis-note { font-size: 11.5px; color: var(--wl-text-3); }
.wt-orbis-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
body .wt-orbis-actions button { height: 28px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12px; }
body .wt-orbis-actions button:not(.mod-cta) { background: transparent; box-shadow: none; border: 1px solid var(--wl-line); color: var(--wl-text-2); }
body .wt-orbis-actions button:not(.mod-cta):hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-panel p.wt-orbis-done { display: flex; align-items: center; gap: 6px; margin: 10px 0 0; font-size: 12px; color: var(--wl-text-2); }
.wt-orbis-done::before { content: ""; width: 6px; height: 6px; flex-shrink: 0; border-radius: 50%; background: var(--wl-success); }
.wt-orbis-typing { display: flex; align-items: center; gap: 4px; height: 24px; }
.wt-orbis-typing i { width: 5px; height: 5px; border-radius: 50%; background: var(--wl-text-3); animation: wt-orbis-dot 1.1s ease-in-out infinite; }
.wt-orbis-typing i:nth-child(2) { animation-delay: .15s; }
.wt-orbis-typing i:nth-child(3) { animation-delay: .3s; }

/* The composer: what Orbis is working with, the message, then quick actions, mode and send. */
.wt-orbis-composer { flex-shrink: 0; margin: 0 12px 12px; padding: 8px 8px 8px 12px; border: 1px solid var(--wl-line); border-radius: var(--r-xl); background: var(--wl-surface); box-shadow: none; transition: border-color var(--wl-quick) var(--wl-ease), box-shadow var(--wl-quick) var(--wl-ease); }
.wt-orbis-composer:focus-within { border-color: var(--wl-selection); box-shadow: 0 0 0 3px color-mix(in srgb, var(--wl-selection) 14%, transparent); }
.wt-orbis-composer-context { display: flex; align-items: center; gap: 6px; min-width: 0; height: 20px; font-size: 11.5px; color: var(--wl-text-3); }
.wt-orbis-composer-context > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-composer-context .wt-glyph { color: var(--wl-text-2); }
.wt-orbis-composer-context .wt-glyph svg { width: 12px; height: 12px; }
.wt-orbis-composer textarea.wt-orbis-input { display: block; width: 100%; min-height: 40px; max-height: 160px; margin: 2px 0 4px; padding: 6px 4px 6px 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; resize: none; font-size: 13.5px; line-height: 1.45; color: var(--wl-text); }
/* The composer shows focus on its frame; `body` lifts this over the shell's focus ring for every field (atlas-system.css). */
body .wt-orbis-composer textarea.wt-orbis-input:is(:focus, :focus-visible) { border: 0; box-shadow: none; outline: none; }
.wt-orbis-composer-row { display: flex; align-items: center; gap: 4px; }
body .wt-orbis-composer-row button.wt-icon-button { width: 30px; height: 30px; border-radius: 50%; }
body .wt-orbis-composer-row button.wt-orbis-mode { display: inline-flex; align-items: center; gap: 5px; height: 28px; margin-inline-start: auto; padding: 0 8px 0 9px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 12px; font-weight: 500; cursor: pointer; }
body .wt-orbis-composer-row button.wt-orbis-mode:hover, body .wt-orbis-composer-row button.wt-orbis-mode[aria-expanded="true"] { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-mode > .wt-glyph:first-child { color: var(--wl-text-2); }
.wt-orbis-mode .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-mode > .wt-glyph:last-child svg { width: 12px; height: 12px; }
body .wt-orbis-composer-row button.wt-orbis-send { width: 30px; height: 30px; border-radius: 50%; background: var(--wl-accent); color: var(--wl-on-accent); transition: background-color var(--wl-quick), color var(--wl-quick), scale var(--wl-quick); }
body .wt-orbis-composer-row button.wt-orbis-send:hover:not(:disabled) { background: color-mix(in srgb, var(--wl-accent) 80%, var(--wl-text)); color: var(--wl-on-accent); }
body .wt-orbis-composer-row button.wt-orbis-send:active:not(:disabled) { scale: .92; }
body .wt-orbis-composer-row button.wt-orbis-send:disabled { background: var(--wl-raised); color: var(--wl-text-3); cursor: default; }
.wt-orbis-send .wt-glyph svg { width: 16px; height: 16px; stroke-width: 2.2; }

/* Quick choices: history, panel position, quick actions and mode. */
.wt-orbis-pop { position: absolute; z-index: 5; min-width: min(220px, calc(100% - 16px)); max-width: calc(100% - 16px); overflow: hidden; padding: 5px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-surface); box-shadow: var(--wl-elev-pop); transform-origin: top right; animation: wt-orbis-pop .14s cubic-bezier(.2,.8,.2,1); }
.wt-orbis-pop.is-up { transform-origin: bottom left; }
.wt-orbis-pop.is-wide { width: 290px; }
body .wt-orbis-pop button.wt-orbis-pop-item { display: flex; align-items: center; gap: 10px; width: 100%; height: 32px; padding: 0 9px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 13px; font-weight: 400; text-align: start; cursor: pointer; }
body .wt-orbis-pop button.wt-orbis-pop-item:hover:not(:disabled), body .wt-orbis-pop button.wt-orbis-pop-item:focus-visible { background: var(--wl-raised); outline: none; }
body .wt-orbis-pop button.wt-orbis-pop-item:disabled { opacity: .5; cursor: default; }
.wt-orbis-pop-item > .wt-glyph:first-child { color: var(--wl-text-2); }
.wt-orbis-pop-item > span:not(.wt-glyph) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-pop-item > .wt-glyph { flex-shrink: 0; }
.wt-orbis-pop-item > small { flex-shrink: 0; font-size: 11px; color: var(--wl-text-3); }
.wt-orbis-pop-item > .wt-orbis-check { color: var(--wl-selection); }
.wt-orbis-pop input.wt-orbis-pop-search { width: 100%; height: 32px; margin-bottom: 4px; padding: 0 10px; border-radius: var(--r-md); font-size: 13px; }
.wt-orbis-pop-list { max-height: 300px; overflow-y: auto; }
.wt-orbis-pop-group { padding: 8px 9px 4px; font-size: 11px; font-weight: 600; color: var(--wl-text-3); }
/* The end of a long history: a quiet row that draws the next chats (boris-panel.mjs showHistory). */
body .wt-orbis-pop button.wt-orbis-pop-item.wt-orbis-pop-more { justify-content: center; margin-top: 2px; color: var(--wl-text-3); font-size: 12px; }
body .wt-orbis-pop button.wt-orbis-pop-item.wt-orbis-pop-more:is(:hover, .is-active) { color: var(--wl-text); }
.wt-orbis-panel p.wt-orbis-pop-empty { margin: 0; padding: 16px 10px; font-size: 12px; color: var(--wl-text-3); text-align: center; }

/* ---- Boris with a model (D-053): steps, thinking, questions, Undo, the composer's chips ---- */
.wt-orbis-composer-context { height: auto; min-height: 22px; margin-bottom: 2px; }
body .wt-orbis-composer-context button.wt-orbis-share { display: inline-flex; align-items: center; gap: 5px; max-width: 100%; height: 22px; padding: 0 7px 0 6px; border: 0; border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: none; color: var(--wl-text-3); font-size: 11.5px; font-weight: 500; cursor: pointer; transition: background-color var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease), opacity var(--wl-quick) var(--wl-ease); }
body .wt-orbis-composer-context button.wt-orbis-share:hover:not(:disabled) { color: var(--wl-text); background: var(--wl-raised); }
body .wt-orbis-composer-context button.wt-orbis-share:disabled { background: transparent; color: var(--wl-text-3); cursor: default; padding-inline: 0; }
.wt-orbis-share > span:not(.wt-glyph) { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-share .wt-glyph { flex-shrink: 0; }
.wt-orbis-composer-context .wt-orbis-share .wt-orbis-share-eye { color: var(--wl-text-3); }
.wt-orbis-share.is-off > span:not(.wt-glyph) { text-decoration: line-through; text-decoration-color: var(--wl-text-3); }
.wt-orbis-composer-context .wt-orbis-share.is-off .wt-glyph, .wt-orbis-composer-context .wt-orbis-share:disabled .wt-glyph { color: var(--wl-text-3); }
body .wt-orbis-composer-row button.wt-orbis-mode { min-width: 0; max-width: 200px; }
.wt-orbis-mode > span:not(.wt-glyph) { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-mode .wt-glyph { flex-shrink: 0; }
body .wt-orbis-composer-row button.wt-orbis-mode.is-missing { color: var(--wl-warning); }
body .wt-orbis-composer-row button.wt-orbis-send.is-stop { background: var(--wl-text); color: var(--wl-bg); }
body .wt-orbis-composer-row button.wt-orbis-send.is-stop:hover { background: var(--wl-text-2); color: var(--wl-bg); }
body .wt-orbis-welcome button.wt-orbis-setup { margin-top: 2px; }
body .wt-orbis-pop button.wt-orbis-pop-item.is-last { position: relative; margin-top: 7px; }
.wt-orbis-pop-item.is-last::before { content: ""; position: absolute; top: -4px; left: 6px; right: 6px; border-top: 1px solid var(--wl-line); }

.wt-orbis-steps { display: flex; flex-direction: column; gap: 1px; margin: 0 0 8px; }
.wt-orbis-steps:not(:first-child) { margin-top: 6px; }
.wt-orbis-tool { display: flex; align-items: center; gap: 7px; min-width: 0; min-height: 24px; font-size: 12px; color: var(--wl-text-2); }
.wt-orbis-tool > .wt-glyph { flex-shrink: 0; color: var(--wl-text-3); }
.wt-orbis-tool > .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-tool-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
body .wt-orbis-tool button.wt-orbis-tool-text { display: block; height: auto; padding: 0; border: 0; background: transparent; box-shadow: none; color: inherit; font-size: inherit; font-weight: inherit; text-align: start; cursor: pointer; }
body .wt-orbis-tool button.wt-orbis-tool-text:hover { color: var(--wl-text); text-decoration: underline; text-decoration-color: var(--wl-text-3); text-underline-offset: 2px; }
.wt-orbis-tool.is-running { color: var(--wl-text); }
.wt-orbis-tool.is-running > .wt-glyph:first-child { color: var(--wl-selection); }
.wt-orbis-tool .wt-orbis-spin { color: var(--wl-selection); animation: wt-orbis-pulse 1s ease-in-out infinite; }
.wt-orbis-tool.is-error, .wt-orbis-tool.is-error .wt-orbis-tool-state { color: var(--wl-danger); }
.wt-orbis-tool.is-skipped { color: var(--wl-text-3); }
.wt-orbis-panel p.wt-orbis-tool-error { margin: 0 0 3px 20px; font-size: 11.5px; line-height: 1.45; color: var(--wl-text-3); }
.wt-orbis-thought { font-size: 12px; color: var(--wl-text-3); }
.wt-orbis-thought > summary { display: flex; align-items: center; gap: 7px; min-height: 24px; list-style: none; cursor: pointer; }
.wt-orbis-thought > summary::-webkit-details-marker { display: none; }
.wt-orbis-thought > summary:hover { color: var(--wl-text-2); }
.wt-orbis-thought > summary .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-thought-text { max-height: 220px; overflow-y: auto; margin: 2px 0 6px 6px; padding: 2px 0 2px 12px; border-left: 2px solid var(--wl-line); line-height: 1.5; white-space: pre-wrap; }
.wt-orbis-text { font-size: 13px; line-height: 1.55; white-space: pre-wrap; }
.wt-orbis-text + .wt-orbis-text { margin-top: 8px; }
.wt-orbis-text.is-markdown { white-space: normal; }
.wt-orbis-panel .wt-orbis-text.is-markdown > :first-child { margin-top: 0; }
.wt-orbis-panel .wt-orbis-text.is-markdown > :last-child { margin-bottom: 0; }
.wt-orbis-panel .wt-orbis-text.is-markdown p { margin: 0 0 .6em; }
.wt-orbis-panel .wt-orbis-text.is-markdown :is(ul, ol) { margin: 0 0 .6em; padding-inline-start: 1.3em; }
.wt-orbis-panel .wt-orbis-text.is-markdown :is(h1, h2, h3, h4) { margin: .8em 0 .3em; font-size: 13.5px; font-weight: 600; }
.wt-orbis-panel .wt-orbis-text.is-markdown code { font-size: 12px; }
.wt-orbis-panel .wt-orbis-text.is-markdown [data-wl-path], .wt-orbis-panel .wt-orbis-text.is-markdown [data-wl-url] { color: var(--wl-text); cursor: pointer; }
.wt-orbis-panel p.wt-orbis-note { margin: 6px 0 0; }
.wt-orbis-error { display: flex; align-items: flex-start; gap: 8px; padding: 10px 12px; border-radius: var(--r-md); background: color-mix(in srgb, var(--wl-danger) 8%, transparent); font-size: 12.5px; }
.wt-orbis-error > .wt-glyph { flex-shrink: 0; margin-top: 2px; color: var(--wl-danger); }
.wt-orbis-error > .wt-glyph svg { width: 14px; height: 14px; }
.wt-orbis-panel .wt-orbis-error p { margin: 0; line-height: 1.5; }
.wt-orbis-error .wt-text-button { display: inline; height: auto; margin-top: 4px; padding: 0; border: 0; background: transparent; box-shadow: none; color: var(--wl-text); font-size: 12px; cursor: pointer; }
.wt-orbis-ask { margin: 4px 0 8px; padding: 12px 14px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-surface); animation: wt-orbis-rise .18s ease; }
.wt-orbis-ask-head { display: flex; align-items: center; gap: 8px; }
.wt-orbis-ask-head > .wt-glyph { flex-shrink: 0; color: var(--wl-text); }
.wt-orbis-ask.is-danger .wt-orbis-ask-head > .wt-glyph { color: var(--wl-danger); }
.wt-orbis-ask strong { font-size: 13px; font-weight: 600; }
.wt-orbis-panel .wt-orbis-ask p { margin: 4px 0 0; font-size: 12px; color: var(--wl-text-2); }
.wt-orbis-ask .wt-orbis-actions { margin-top: 10px; }
body .wt-orbis-ask .wt-orbis-actions button.mod-warning { background: var(--wl-danger); color: var(--wl-on-accent); }
body .wt-orbis-ask .wt-orbis-actions button.mod-warning:hover { background: color-mix(in srgb, var(--wl-danger) 85%, var(--wl-text)); color: var(--wl-on-accent); }
.wt-orbis-foot { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 11.5px; color: var(--wl-text-3); }
body .wt-orbis-foot button.wt-orbis-undo { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 11.5px; cursor: pointer; }
body .wt-orbis-foot button.wt-orbis-undo:hover:not(:disabled) { color: var(--wl-text); background: var(--wl-raised); }
body .wt-orbis-foot button.wt-orbis-undo:disabled { opacity: .5; cursor: default; }
.wt-orbis-undo .wt-glyph svg { width: 12px; height: 12px; }
.wt-orbis-done.is-undone::before { background: var(--wl-text-3); }
@keyframes wt-orbis-pulse { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
@keyframes wt-orbis-fade { from { opacity: 0; } }

/* ---- Boris's chat, polished (D-054): grouped steps, helpers, change cards, tables and code,
   copy, attachments, the context ring and drawer ---- */
/* Copy buttons: quiet until wanted. */
body .wt-orbis-panel button.wt-orbis-copy { width: 24px; height: 24px; padding: 0; border-radius: var(--r-sm); color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-copy:hover { color: var(--wl-text); background: var(--wl-raised); }
body .wt-orbis-panel button.wt-orbis-copy.is-copied { color: var(--wl-success); }
.wt-orbis-copy .wt-glyph svg { width: 13px; height: 13px; }
body .wt-orbis-panel button.wt-orbis-msg-copy { position: absolute; right: calc(100% + 4px); bottom: 2px; opacity: 0; transition: opacity var(--wl-quick) var(--wl-ease); }
.wt-orbis-bubble:hover button.wt-orbis-msg-copy, .wt-orbis-bubble button.wt-orbis-msg-copy:focus-visible { opacity: 1; }
@media (pointer: coarse) { body .wt-orbis-panel button.wt-orbis-msg-copy { opacity: .7; } }

/* What a message carried: pictures and context. */
.wt-orbis-sent { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.wt-orbis-sent-image { width: 76px; height: 76px; border-radius: var(--r-md); object-fit: cover; box-shadow: 0 0 0 1px var(--wl-line); }
.wt-orbis-sent-image:only-child { width: auto; height: auto; max-width: 220px; max-height: 180px; }
.wt-orbis-ref { display: inline-flex; align-items: center; gap: 5px; max-width: 100%; height: 24px; padding: 0 8px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text-3); font-size: 11.5px; font-weight: 500; }
.wt-orbis-ref > span:not(.wt-glyph) { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-ref > .wt-glyph { flex-shrink: 0; color: var(--wl-text-2); }
.wt-orbis-ref .wt-glyph svg { width: 12px; height: 12px; }

/* A run of steps as one group. */
.wt-orbis-activity { margin: 2px 0 8px; border-radius: var(--r-md); }
.wt-orbis-activity:not(:first-child) { margin-top: 6px; }
.wt-orbis-activity-head { display: flex; align-items: center; gap: 7px; min-height: 28px; padding: 0 8px; margin: 0 -8px; border-radius: var(--r-md); list-style: none; cursor: pointer; font-size: 12px; color: var(--wl-text-2); transition: background-color var(--wl-quick) var(--wl-ease); }
.wt-orbis-activity-head::-webkit-details-marker, .wt-orbis-agent > summary::-webkit-details-marker, .wt-orbis-change > summary::-webkit-details-marker, .wt-orbis-part > summary::-webkit-details-marker { display: none; }
.wt-orbis-activity-head:hover { background: var(--wl-raised); color: var(--wl-text); }
.wt-orbis-activity-head > .wt-glyph { flex-shrink: 0; }
.wt-orbis-activity-head > .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-activity-icon { color: var(--wl-text-3); }
.wt-orbis-activity-icon.is-error { color: var(--wl-danger); }
.wt-orbis-activity-head .wt-orbis-spin { color: var(--wl-selection); animation: wt-orbis-pulse 1s ease-in-out infinite; }
.wt-orbis-activity-words { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; }
.wt-orbis-activity-words > span { flex-shrink: 0; }
.wt-orbis-activity-words > span + span::before { content: "·"; margin-right: 6px; color: var(--wl-text-3); }
.wt-orbis-activity-words > .wt-orbis-activity-now { flex-shrink: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--wl-text); }
.wt-orbis-activity-words > .wt-orbis-activity-count, .wt-orbis-activity-words > .wt-orbis-activity-time { color: var(--wl-text-3); }
.wt-orbis-activity-words > .is-error { color: var(--wl-danger); }
.wt-orbis-activity-chevron { margin-inline-start: auto; color: var(--wl-text-3); transition: rotate var(--wl-quick) var(--wl-ease); }
details[open] > summary > .wt-orbis-activity-chevron { rotate: 90deg; }
.wt-orbis-activity > .wt-orbis-steps { margin: 4px 0 2px 6px; padding: 2px 0 2px 12px; border-left: 1px solid var(--wl-line); }

/* While Boris works: what it is doing now, a ticking clock, and the newest line of its thinking. */
.wt-orbis-live { display: flex; align-items: center; gap: 8px; min-height: 26px; margin-top: 2px; font-size: 12px; color: var(--wl-text); }
.wt-orbis-live-dot { flex-shrink: 0; width: 7px; height: 7px; border-radius: 50%; background: var(--wl-selection); animation: wt-orbis-pulse 1.2s ease-in-out infinite; }
.wt-orbis-live-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-live-time { flex-shrink: 0; color: var(--wl-text-3); font-variant-numeric: tabular-nums; }
.wt-orbis-panel p.wt-orbis-live-thought { margin: 0 0 0 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; font-style: italic; line-height: 1.5; color: var(--wl-text-3); }
.wt-orbis-activity-words > .wt-orbis-activity-now { flex-shrink: 0; color: var(--wl-text); }
@media (prefers-reduced-motion: reduce) { .wt-orbis-live, .wt-orbis-live-dot { animation: none; } }

/* Helpers: one row each, folding open to their steps and report. */
.wt-orbis-agents { display: flex; flex-direction: column; gap: 4px; margin: 4px 0 6px 20px; }
.wt-orbis-agent { border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); }
.wt-orbis-agent > summary { display: flex; align-items: center; gap: 7px; min-height: 32px; padding: 0 10px; list-style: none; cursor: pointer; font-size: 12px; }
.wt-orbis-agent > summary > .wt-glyph { flex-shrink: 0; color: var(--wl-text-2); }
.wt-orbis-agent > summary > .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-agent.is-error > summary > .wt-glyph:first-child { color: var(--wl-danger); }
.wt-orbis-agent .wt-orbis-spin { animation: wt-orbis-pulse 1s ease-in-out infinite; }
.wt-orbis-agent-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; color: var(--wl-text); }
.wt-orbis-agent-meta { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--wl-text-3); }
.wt-orbis-agent-body { padding: 2px 10px 8px 30px; }
.wt-orbis-panel p.wt-orbis-agent-model { margin: 0 0 4px; font-size: 11px; color: var(--wl-text-3); }
.wt-orbis-panel .wt-orbis-agent-report { margin: 6px 0 0; padding: 8px 10px; border-radius: var(--r-md); background: var(--wl-surface); font-size: 12px; line-height: 1.5; color: var(--wl-text-2); white-space: pre-wrap; overflow-wrap: anywhere; }
.wt-orbis-panel .wt-orbis-agent-report.is-markdown { white-space: normal; }
.wt-orbis-agent-report.is-markdown > :first-child { margin-top: 0; }
.wt-orbis-agent-report.is-markdown > :last-child { margin-bottom: 0; }
.wt-orbis-agent-report.is-markdown :is(p, ul, ol) { margin: 0 0 6px; }
.wt-orbis-agent-report.is-markdown :is(ul, ol) { padding-left: 18px; }
.wt-orbis-agent-report.is-markdown strong { color: var(--wl-text); font-weight: 600; }

/* What changed: one card per file, type or map. */
.wt-orbis-changes { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; animation: wt-orbis-fade .2s ease; }
.wt-orbis-change { border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); overflow: hidden; }
.wt-orbis-change-head { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 7px 8px 7px 8px; list-style: none; }
summary.wt-orbis-change-head { cursor: pointer; }
summary.wt-orbis-change-head:hover { background: var(--wl-raised); }
.wt-orbis-change-face { position: relative; display: grid; place-items: center; flex-shrink: 0; width: 34px; height: 34px; overflow: hidden; border-radius: var(--r-md); background: var(--wl-surface); color: var(--wl-text-2); }
.wt-orbis-change-face .wt-glyph svg { width: 16px; height: 16px; }
.wt-orbis-initials { font-size: 11.5px; font-weight: 600; letter-spacing: .02em; }
.wt-orbis-change-face img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: wt-orbis-fade .2s ease; }
.wt-orbis-change-words { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.wt-orbis-change-words > * { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-change-words strong { font-size: 13px; font-weight: 600; }
.wt-orbis-change-words small { font-size: 11.5px; color: var(--wl-text-3); }
.wt-orbis-badge { flex-shrink: 0; padding: 2px 7px; border-radius: var(--r-pill); font-size: 10.5px; font-weight: 600; letter-spacing: .02em; background: var(--wl-raised); color: var(--wl-text-3); }
.wt-orbis-badge.is-new { background: color-mix(in srgb, var(--wl-success) 16%, transparent); color: var(--wl-success); }
.wt-orbis-badge.is-edit, .wt-orbis-badge.is-rename { background: color-mix(in srgb, var(--wl-accent) 14%, transparent); color: var(--wl-text); }
.wt-orbis-badge.is-trash, .wt-orbis-badge.is-gone { background: color-mix(in srgb, var(--wl-danger) 12%, transparent); color: var(--wl-danger); }
body .wt-orbis-panel button.wt-orbis-change-open { flex-shrink: 0; width: 28px; height: 28px; border-radius: var(--r-md); color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-change-open:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-change-open .wt-glyph svg { width: 14px; height: 14px; }
.wt-orbis-change-head > .wt-orbis-activity-chevron { margin-inline-start: 0; }
.wt-orbis-change-body { display: flex; flex-direction: column; gap: 6px; padding: 4px 12px 12px 52px; animation: wt-orbis-fade .15s ease; }
.wt-orbis-diff { display: flex; flex-direction: column; gap: 1px; font-size: 12px; }
.wt-orbis-diff-label { font-size: 11px; font-weight: 500; color: var(--wl-text-3); }
.wt-orbis-diff-values { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; line-height: 1.5; overflow-wrap: anywhere; }
.wt-orbis-diff del { color: var(--wl-text-3); text-decoration-color: color-mix(in srgb, var(--wl-danger) 60%, transparent); }
.wt-orbis-diff del::after { content: " →"; display: inline-block; margin-left: 6px; text-decoration: none; color: var(--wl-text-3); }
.wt-orbis-diff ins { text-decoration: none; color: var(--wl-text); }
.wt-orbis-change-notes { margin: 0; padding-inline-start: 1.1em; font-size: 12px; color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-changes-more { align-self: flex-start; height: 26px; padding: 0 10px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 12px; cursor: pointer; }
body .wt-orbis-panel button.wt-orbis-changes-more:hover { background: var(--wl-raised); }

/* Words: headings, lists, quotes, tables and code read like a polished chat. */
.wt-orbis-panel .wt-orbis-text.is-markdown h1, .wt-orbis-panel .wt-orbis-text.is-markdown h2 { margin: 1em 0 .4em; font-size: 14.5px; font-weight: 650; letter-spacing: -.01em; }
.wt-orbis-panel .wt-orbis-text.is-markdown h3, .wt-orbis-panel .wt-orbis-text.is-markdown h4 { margin: .9em 0 .3em; font-size: 13px; font-weight: 600; }
.wt-orbis-panel .wt-orbis-text.is-markdown li { margin: .15em 0; }
.wt-orbis-panel .wt-orbis-text.is-markdown li > :is(ul, ol) { margin: .15em 0 0; }
.wt-orbis-panel .wt-orbis-text.is-markdown strong { font-weight: 600; }
.wt-orbis-panel .wt-orbis-text.is-markdown blockquote { margin: 0 0 .6em; padding: 2px 0 2px 12px; border-left: 2px solid var(--wl-line); color: var(--wl-text-2); }
.wt-orbis-panel .wt-orbis-text.is-markdown hr { margin: 1em 0; border: 0; border-top: 1px solid var(--wl-line); }
.wt-orbis-panel .wt-orbis-text.is-markdown :not(pre) > code { padding: 1px 5px; border-radius: var(--r-sm); background: var(--wl-raised); font-size: 11.5px; }
.wt-orbis-table, .wt-orbis-code { margin: .3em 0 .8em; overflow: hidden; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); }
.wt-orbis-block-bar { display: flex; align-items: center; gap: 2px; height: 30px; padding: 0 4px 0 10px; border-bottom: 1px solid var(--wl-line); background: var(--wl-surface); font-size: 11px; color: var(--wl-text-3); }
.wt-orbis-block-bar > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-table-scroll { overflow-x: auto; }
.wt-orbis-panel .wt-orbis-table table { width: 100%; margin: 0; border-collapse: collapse; font-size: 12px; line-height: 1.45; }
.wt-orbis-panel .wt-orbis-table :is(th, td) { padding: 7px 10px; border: 0; border-bottom: 1px solid var(--wl-line); text-align: start; vertical-align: top; }
.wt-orbis-panel .wt-orbis-table th { font-weight: 600; color: var(--wl-text-2); white-space: nowrap; background: var(--wl-bg); }
.wt-orbis-panel .wt-orbis-table tr:last-child td { border-bottom: 0; }
.wt-orbis-panel .wt-orbis-table tbody tr:nth-child(even) td { background: color-mix(in srgb, var(--wl-surface) 55%, transparent); }
.wt-orbis-panel .wt-orbis-code pre { margin: 0; padding: 10px 12px; overflow-x: auto; border: 0; border-radius: 0; background: transparent; font-size: 11.5px; line-height: 1.55; }
.wt-orbis-panel .wt-orbis-code pre code { padding: 0; background: transparent; white-space: pre; }

/* Under an answer: copy, its changes, Undo, and its size. */
.wt-orbis-foot { flex-wrap: wrap; gap: 6px; }
.wt-orbis-foot > .wt-orbis-copy { margin-inline-start: -4px; }
.wt-orbis-foot > .wt-orbis-done { margin: 0; }
.wt-orbis-usage { margin-inline-start: auto; font-variant-numeric: tabular-nums; }

/* The composer: what goes with the message, and how full Boris's memory is. */
.wt-orbis-tray { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 4px 0 2px; animation: wt-orbis-fade .15s ease; }
.wt-orbis-tray[hidden] { display: none; }
.wt-orbis-tray-image { position: relative; width: 52px; height: 52px; }
.wt-orbis-tray-image img { width: 100%; height: 100%; border-radius: var(--r-md); object-fit: cover; box-shadow: 0 0 0 1px var(--wl-line); }
body .wt-orbis-panel .wt-orbis-tray-image button.wt-orbis-tray-remove { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; padding: 0; border-radius: 50%; background: var(--wl-bg); box-shadow: 0 0 0 1px var(--wl-line), 0 1px 3px color-mix(in srgb, var(--wl-bg) 30%, transparent); color: var(--wl-text-2); }
body .wt-orbis-panel .wt-orbis-ref button.wt-orbis-tray-remove { width: 16px; height: 16px; margin-inline-end: -4px; padding: 0; border-radius: 50%; background: transparent; box-shadow: none; color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-tray-remove:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-tray-remove .wt-glyph svg { width: 11px; height: 11px; }
.wt-orbis-panel p.wt-orbis-tray-note { flex-basis: 100%; margin: 0; font-size: 11.5px; color: var(--wl-warning); }
.wt-orbis-composer input.wt-orbis-file { display: none; }
body .wt-orbis-composer-row button.wt-orbis-ring { display: inline-flex; align-items: center; gap: 4px; flex-shrink: 0; height: 28px; padding: 0 7px 0 6px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 11px; font-weight: 500; font-variant-numeric: tabular-nums; cursor: pointer; }
body .wt-orbis-composer-row button.wt-orbis-ring:hover, body .wt-orbis-composer-row button.wt-orbis-ring[aria-expanded="true"] { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-ring svg { width: 16px; height: 16px; }
.wt-orbis-ring-track { fill: none; stroke: var(--wl-line); stroke-width: 2.4; }
.wt-orbis-ring-fill { fill: none; stroke: var(--wl-accent); stroke-width: 2.4; stroke-linecap: round; transition: stroke-dasharray var(--wl-long) var(--wl-ease); }
.wt-orbis-ring.is-full .wt-orbis-ring-fill { stroke: var(--wl-warning); }
.wt-orbis-panel.is-dropping .wt-orbis-composer { border-color: var(--wl-selection); box-shadow: 0 0 0 3px color-mix(in srgb, var(--wl-selection) 22%, transparent); }

/* Add context: many picked without leaving the chat. */
.wt-orbis-pop.is-picker { display: flex; flex-direction: column; width: 320px; }
.wt-orbis-filters { display: flex; gap: 4px; padding: 0 2px 6px; }
body .wt-orbis-filters button { height: 24px; padding: 0 10px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 11.5px; cursor: pointer; }
body .wt-orbis-filters button:hover { background: var(--wl-raised); color: var(--wl-text); }
body .wt-orbis-filters button[aria-checked="true"] { background: var(--wl-raised); color: var(--wl-text); font-weight: 500; }
body .wt-orbis-pop button.wt-orbis-pick { height: auto; min-height: 38px; padding: 5px 9px; }
.wt-orbis-pick > span:not(.wt-glyph) { display: flex; flex-direction: column; }
.wt-orbis-pick strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; font-weight: 500; }
.wt-orbis-pick small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; color: var(--wl-text-3); }
.wt-orbis-pick > .wt-orbis-check { opacity: 0; transition: opacity var(--wl-quick) var(--wl-ease); }
.wt-orbis-pick[aria-selected="true"] > .wt-orbis-check { opacity: 1; }
body .wt-orbis-pop button.wt-orbis-pick[aria-selected="true"] { background: var(--wl-selection-soft); }
.wt-orbis-picker-foot { display: flex; align-items: center; gap: 8px; margin-top: 4px; padding: 6px 4px 2px 8px; border-top: 1px solid var(--wl-line); font-size: 11.5px; color: var(--wl-text-3); }
.wt-orbis-picker-foot > span { flex: 1; }
body .wt-orbis-picker-foot button { height: 26px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12px; }

/* The context drawer takes the chat's place in the panel. */
.wt-orbis-inner.has-drawer > .wt-orbis-chat { display: none; }
.wt-orbis-drawer { display: flex; flex-direction: column; flex: 1; min-height: 0; animation: wt-orbis-fade .16s ease; }
.wt-orbis-drawer-head { display: flex; align-items: center; gap: 6px; padding: 10px 12px 0 14px; }
.wt-orbis-drawer-tabs { display: flex; gap: 2px; flex: 1; min-width: 0; padding: 3px; border-radius: var(--r-md); background: var(--wl-surface); }
body .wt-orbis-drawer-tabs button.wt-orbis-drawer-tab { display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: 1; min-width: 0; height: 28px; padding: 0 8px; border: 0; border-radius: var(--r-md); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 12px; font-weight: 500; cursor: pointer; }
body .wt-orbis-drawer-tabs button.wt-orbis-drawer-tab:hover { color: var(--wl-text); }
body .wt-orbis-drawer-tabs button.wt-orbis-drawer-tab[aria-selected="true"] { background: var(--wl-raised); color: var(--wl-text); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-orbis-drawer-tab .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-drawer-body { flex: 1; min-height: 0; overflow-y: auto; padding: 16px 16px 18px; font-size: 12.5px; }
.wt-orbis-panel p.wt-orbis-drawer-lead { margin: 0 0 14px; font-size: 12px; line-height: 1.55; color: var(--wl-text-2); }
.wt-orbis-panel p.wt-orbis-drawer-foot { margin: 14px 0 0; font-size: 11px; line-height: 1.5; color: var(--wl-text-3); }
.wt-orbis-panel p.wt-orbis-drawer-warn { margin: 12px 0 0; padding: 8px 10px; border-radius: var(--r-md); background: color-mix(in srgb, var(--wl-warning) 12%, transparent); font-size: 12px; color: var(--wl-text); }
.wt-orbis-meter { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.wt-orbis-meter-total { display: flex; flex-direction: column; gap: 2px; }
.wt-orbis-meter-total strong { font-family: var(--wl-font-mono); font-size: 20px; font-weight: 500; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.wt-orbis-meter-total span { font-size: 11.5px; color: var(--wl-text-3); }
.wt-orbis-meter-bar { display: flex; gap: 2px; height: 10px; overflow: hidden; border-radius: var(--r-pill); background: var(--wl-raised); }
.wt-orbis-meter-bar > span { height: 100%; transition: width var(--wl-long) var(--wl-ease); }
.wt-orbis-meter-bar > span:first-child { border-radius: var(--r-pill) 0 0 var(--r-pill); }
.wt-orbis-parts { display: flex; flex-direction: column; border: 1px solid var(--wl-line); border-radius: var(--r-md); overflow: hidden; }
.wt-orbis-part + .wt-orbis-part { border-top: 1px solid var(--wl-line); }
.wt-orbis-part > summary { display: flex; align-items: center; gap: 9px; min-height: 36px; padding: 0 10px 0 12px; list-style: none; cursor: pointer; }
.wt-orbis-part > summary:hover { background: var(--wl-raised); }
.wt-orbis-part-dot { flex-shrink: 0; width: 8px; height: 8px; border-radius: var(--r-xs); }
.wt-orbis-part-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.wt-orbis-part-note { flex-shrink: 0; font-size: 11px; color: var(--wl-text-3); }
.wt-orbis-part-size { flex-shrink: 0; font-size: 11.5px; font-variant-numeric: tabular-nums; color: var(--wl-text-3); }
.wt-orbis-panel pre.wt-orbis-part-text { max-height: 240px; margin: 0; padding: 10px 12px; overflow: auto; border-top: 1px solid var(--wl-line); background: var(--wl-surface); font-size: 11px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--wl-text-3); animation: wt-orbis-fade .15s ease; }
.wt-orbis-drawer-section + .wt-orbis-drawer-section { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--wl-line); }
.wt-orbis-drawer-section h3 { margin: 0 0 8px; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--wl-text-3); }
.wt-orbis-setting { display: flex; align-items: center; gap: 12px; padding: 8px 0; cursor: default; }
label.wt-orbis-setting { cursor: pointer; }
.wt-orbis-setting > span:first-child { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.wt-orbis-setting strong { font-size: 12.5px; font-weight: 500; }
.wt-orbis-setting small { font-size: 11.5px; line-height: 1.45; color: var(--wl-text-3); }
.wt-orbis-setting select.dropdown { flex-shrink: 0; max-width: 46%; height: 28px; font-size: 12px; }
.wt-orbis-switch { position: relative; flex-shrink: 0; display: inline-flex; width: 30px; height: 18px; cursor: pointer; }
.wt-orbis-switch input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.wt-orbis-switch > span { width: 100%; height: 100%; border-radius: var(--r-pill); background: var(--wl-line-strong); transition: background-color var(--wl-quick) var(--wl-ease); pointer-events: none; }
.wt-orbis-switch > span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--wl-text-2); box-shadow: 0 1px 2px color-mix(in srgb, var(--wl-bg) 45%, transparent); transition: translate var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); }
.wt-orbis-switch input:checked + span { background: var(--wl-accent); }
.wt-orbis-switch input:checked + span::after { background: var(--wl-on-accent); }
.wt-orbis-switch input:checked + span::after { translate: 12px 0; }
.wt-orbis-switch input:focus-visible + span { outline: 2px solid var(--wl-selection); outline-offset: 2px; }
.wt-orbis-seg { display: inline-flex; flex-shrink: 0; gap: 2px; padding: 2px; border-radius: var(--r-md); background: var(--wl-surface); }
body .wt-orbis-seg button { height: 24px; min-width: 28px; padding: 0 9px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 11.5px; cursor: pointer; }
body .wt-orbis-seg button[aria-checked="true"] { background: var(--wl-bg); color: var(--wl-text); box-shadow: 0 0 0 1px var(--wl-line); }
body .wt-orbis-panel button.wt-orbis-drawer-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; height: auto; padding: 0; border: 0; background: transparent; box-shadow: none; color: var(--wl-text); font-size: 12px; cursor: pointer; }
.wt-orbis-drawer-more .wt-glyph svg { width: 13px; height: 13px; }
/* Instructions: a list with switches, and an editor in place. */
.wt-orbis-rules { display: flex; flex-direction: column; gap: 6px; }
.wt-orbis-rule { display: flex; align-items: center; gap: 10px; padding: 8px 6px 8px 10px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); }
.wt-orbis-rule.is-off { opacity: .6; }
body .wt-orbis-panel button.wt-orbis-rule-words { display: flex; flex-direction: column; align-items: flex-start; flex: 1; min-width: 0; height: auto; padding: 0; border: 0; background: transparent; box-shadow: none; text-align: start; cursor: pointer; }
.wt-orbis-rule-words > * { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-orbis-rule-words strong { font-size: 12.5px; font-weight: 500; color: var(--wl-text); }
.wt-orbis-rule-words small { font-size: 11.5px; color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-rule-when { flex-shrink: 0; height: 22px; padding: 0 8px; border: 0; border-radius: var(--r-pill); background: color-mix(in srgb, var(--wl-accent) 12%, transparent); box-shadow: none; color: var(--wl-text); font-size: 10.5px; font-weight: 600; cursor: pointer; }
body .wt-orbis-panel button.wt-orbis-rule-when.is-relevant { background: var(--wl-raised); color: var(--wl-text-2); }
body .wt-orbis-panel button.wt-orbis-rule-delete { flex-shrink: 0; width: 26px; height: 26px; border-radius: var(--r-sm); color: var(--wl-text-3); }
body .wt-orbis-panel button.wt-orbis-rule-delete:hover { color: var(--wl-danger); background: var(--wl-raised); }
.wt-orbis-rule-delete .wt-glyph svg { width: 13px; height: 13px; }
body .wt-orbis-panel button.wt-orbis-rule-add { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; border: 1px dashed var(--wl-line); border-radius: var(--r-md); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 12px; cursor: pointer; }
body .wt-orbis-panel button.wt-orbis-rule-add:hover { color: var(--wl-text); background: var(--wl-raised); }
.wt-orbis-rule-add .wt-glyph svg { width: 13px; height: 13px; }
.wt-orbis-rule-editor { display: flex; flex-direction: column; gap: 8px; padding: 10px; border: 1px solid var(--wl-selection); border-radius: var(--r-md); background: var(--wl-bg); animation: wt-orbis-fade .15s ease; }
.wt-orbis-rule-editor .wt-orbis-field { width: 100%; font-size: 12.5px; }
.wt-orbis-rule-editor textarea.wt-orbis-field { min-height: 96px; resize: vertical; line-height: 1.5; }
.wt-orbis-rule-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.wt-orbis-rule-foot > .wt-orbis-seg { margin-inline-end: auto; }
body .wt-orbis-rule-foot > button { height: 28px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12px; }
@media (prefers-reduced-motion: reduce) { .wt-orbis-activity > .wt-orbis-steps, .wt-orbis-agent-body, .wt-orbis-changes, .wt-orbis-change-body, .wt-orbis-tray, .wt-orbis-drawer, .wt-orbis-part-text, .wt-orbis-rule-editor, .wt-orbis-change-face img, .wt-orbis-activity-head .wt-orbis-spin, .wt-orbis-agent .wt-orbis-spin { animation: none; } }

/* ---- Settings → Boris ---- */
/* The same centred column, title and line as Project and File Types; then a row of tabs, one part shown at a time. */
.wt-bs { container-type: inline-size; box-sizing: border-box; width: min(860px, 100%); margin-inline: auto; padding: 42px 46px 70px; }
.wt-bs > h2 { margin: 0; padding: 0; }
.wt-bs > .wb-settings-description { margin: 10px 0 22px; max-width: 650px; font-size: 14px; }
.wt-bs-tabs { display: flex; flex-wrap: wrap; gap: 2px; padding: 3px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); }
body .wt-bs-tabs button.wt-bs-tab { flex: 1 1 auto; display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 32px; padding: 0 12px; border: 0; border-radius: var(--r-sm); background: none; box-shadow: none; color: var(--wl-text-2); font-size: 13px; font-weight: 500; cursor: pointer; transition: background-color var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
body .wt-bs-tabs button.wt-bs-tab:hover { color: var(--wl-text); }
body .wt-bs-tabs button.wt-bs-tab[aria-selected="true"] { color: var(--wl-text); background: var(--wl-raised); }
.wt-bs-tab .wt-glyph svg { width: 15px; height: 15px; }
.wt-bs-body > .wt-bs-section:first-child { margin-top: 22px; }
.wt-bs-section { margin-top: 26px; }
.wt-bs-section > h3 { padding: 0; }
.wt-bs-section > h3 { margin: 0 0 10px; font-size: 15px; font-weight: 600; }
.wt-bs-where { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
body .wt-bs-where button.wt-bs-where-item { display: flex; align-items: flex-start; justify-content: flex-start; gap: 12px; height: auto; padding: 14px; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); box-shadow: none; text-align: start; white-space: normal; cursor: pointer; transition: border-color var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); }
body .wt-bs-where button.wt-bs-where-item:hover { background: var(--wl-raised); }
body .wt-bs-where button.wt-bs-where-item[aria-checked="true"] { border-color: var(--wl-selection); background: color-mix(in srgb, var(--wl-selection) 7%, var(--wl-bg)); }
.wt-bs-where-item > .wt-glyph { flex-shrink: 0; margin-top: 1px; color: var(--wl-text-2); }
.wt-bs-where-item > .wt-glyph svg { width: 20px; height: 20px; }
.wt-bs-where-item > span { display: flex; flex-direction: column; gap: 3px; }
.wt-bs-where-item strong { font-size: 14px; font-weight: 600; color: var(--wl-text); }
.wt-bs-where-item small { font-size: 12px; line-height: 1.45; color: var(--wl-text-3); }
.wt-bs-panel { display: grid; gap: 16px; margin-top: 18px; }
.wt-bs-row { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 4px 16px; align-items: start; }
.wt-bs-label { padding-top: 6px; font-size: 13px; font-weight: 500; color: var(--wl-text); }
.wt-bs-value { min-width: 0; }
.wt-bs-row > .wt-bs-hint, .wt-bs-hint { grid-column: 2; display: block; margin: 0; font-size: 12px; line-height: 1.45; color: var(--wl-text-3); }
.wt-bs-hint.is-error { color: var(--wl-danger); }
.wt-bs-panel > .wt-bs-generation-controls, .wt-bs-panel > .wt-bs-generation-status { grid-column: 1 / -1; }
.wt-bs-generation-controls { display: grid; gap: 16px; }
.wt-bs-chips { display: flex; flex-wrap: wrap; gap: 6px; }
body .wt-bs-chips button { height: 30px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12.5px; }
body .wt-bs-chips button[aria-checked="true"] { background: var(--wl-accent); color: var(--wl-on-accent); }
.wt-bs input.wt-bs-input { width: 100%; max-width: 440px; height: 32px; }
.wt-bs select.dropdown { min-width: 120px; }
.wt-bs-status { margin: 6px 0 8px; font-size: 12px; color: var(--wl-text-3); }
.wt-bs-status.is-error { color: var(--wl-danger); }
.wt-bs-models { display: flex; flex-direction: column; gap: 2px; max-height: 280px; overflow-y: auto; padding: 4px; border: 1px solid var(--wl-line); border-radius: var(--r-md); }
.wt-bs-models:empty { display: none; }
.wt-bs-models.is-tall { max-height: 380px; }
.wt-bs-models > .wt-bs-hint { padding: 8px 10px; }
body .wt-bs-models button.wt-bs-model { display: flex; align-items: center; justify-content: flex-start; gap: 10px; width: 100%; height: auto; min-height: 40px; padding: 6px 10px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; text-align: start; white-space: normal; cursor: pointer; }
body .wt-bs-models button.wt-bs-model:hover { background: var(--wl-raised); }
body .wt-bs-models button.wt-bs-model[aria-checked="true"] { background: var(--wl-selection-soft); }
.wt-bs-model > span:first-of-type { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.wt-bs-model strong { overflow: hidden; text-overflow: ellipsis; font-size: 13px; font-weight: 500; color: var(--wl-text); }
.wt-bs-model small { font-size: 11.5px; color: var(--wl-text-3); }
.wt-bs-model small.is-warn { color: var(--wl-warning); }
.wt-bs-tag { flex-shrink: 0; padding: 1px 7px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--wl-success) 16%, transparent); color: var(--wl-text); font-size: 10.5px; font-weight: 600; }
.wt-bs-check { flex-shrink: 0; color: var(--wl-selection); }
/* Who paints (Images): the model list's groups, each model's price on its right (DESIGN-SYSTEM.md, "Model list") */
.wt-bs-group { padding: 10px 10px 4px; color: var(--wl-text-3); font-size: 11.5px; font-weight: 600; }
.wt-bs-group:first-child { padding-top: 4px; }
.wt-bs-price { flex-shrink: 0; color: var(--wl-text-2); font-family: var(--wl-font-mono); font-size: 11.5px; font-variant-numeric: tabular-nums; }
body .wt-bs-models button.wt-bs-model:disabled { cursor: default; opacity: 1; }
body .wt-bs-models button.wt-bs-model:disabled:hover { background: transparent; }
.wt-bs-model:disabled strong, .wt-bs-model:disabled .wt-bs-price { color: var(--wl-text-3); }
body .wt-bs button.wt-bs-refresh { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; height: 30px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12.5px; }
.wt-bs-refresh .wt-glyph svg { width: 13px; height: 13px; }
.wt-bs-key { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.wt-bs-key > .wt-glyph { color: var(--wl-text-2); }
.wt-bs-key > span { font-size: 13px; }
.wt-bs-key input.wt-bs-input { flex: 1 1 220px; }
.wt-bs .wt-text-button { display: inline; height: auto; padding: 0; border: 0; background: transparent; box-shadow: none; color: var(--wl-text); font-size: inherit; cursor: pointer; }
.wt-bs-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 8px; }
.wt-bs-filters input.wt-bs-input { flex: 1 1 220px; }
.wt-bs-free, .wt-bs-toggle { display: flex; align-items: center; gap: 8px; font-size: 12.5px; cursor: pointer; }
.wt-bs-toggle { align-items: flex-start; gap: 10px; max-width: 560px; }
.wt-bs-toggle input { margin-top: 3px; }
.wt-bs-toggle > span { display: flex; flex-direction: column; gap: 3px; }
.wt-bs-toggle strong { font-size: 13px; font-weight: 500; }
.wt-bs-toggle small { font-size: 12px; line-height: 1.45; color: var(--wl-text-3); }
.wt-bs-notes { margin: 0; padding-inline-start: 18px; font-size: 12.5px; line-height: 1.5; color: var(--wl-text-3); }
.wt-bs-notes li + li { margin-top: 4px; }
@container (max-width: 560px) {
  .wt-bs-where { grid-template-columns: 1fr; }
  .wt-bs-row { grid-template-columns: minmax(0, 1fr); }
  .wt-bs-label { padding-top: 0; }
  .wt-bs-row > .wt-bs-hint, .wt-bs-hint { grid-column: 1; }
}
@media (prefers-reduced-motion: reduce) { .wt-orbis-tool .wt-orbis-spin, .wt-orbis-ask { animation: none; } }

@keyframes wt-orbis-morph { 0%, 100% { border-radius: 34% 38% 36% 32% / 36% 32% 38% 34%; } 33% { border-radius: 40% 32% 34% 38% / 32% 38% 34% 40%; } 66% { border-radius: 32% 36% 40% 34% / 38% 34% 32% 36%; } }
@keyframes wt-orbis-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -3px; } }
@keyframes wt-orbis-bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -4px; } }
@keyframes wt-orbis-glow { 0%, 100% { opacity: .55; scale: .92; } 50% { opacity: 1; scale: 1.08; } }
@keyframes wt-orbis-squish { 0% { scale: 1; } 30% { scale: 1.12 .9; } 55% { scale: .95 1.06; } 80% { scale: 1.02 .98; } 100% { scale: 1; } }
@keyframes wt-orbis-think { 0%, 100% { scale: 1; } 50% { scale: 1.08 .94; } }
@keyframes wt-orbis-twinkle { 0%, 100% { opacity: .35; scale: .7; rotate: 0deg; } 50% { opacity: 1; scale: 1; rotate: 20deg; } }
@keyframes wt-orbis-hop { 0% { translate: 0 0; scale: 1; } 20% { translate: 0 0; scale: 1.08 .9; } 50% { translate: 0 -.1em; scale: .96 1.05; } 75% { translate: 0 0; scale: 1.03 .97; } 100% { translate: 0 0; scale: 1; } }
@keyframes wt-orbis-squint { 0% { transform: scaleY(1); } 15%, 70% { transform: scaleY(.35); } 100% { transform: scaleY(1); } }
@keyframes wt-boris-flow { 0% { translate: 0 0; } 100% { translate: -44.444% -44.444%; } }
@keyframes wt-orbis-breathe { 0%, 100% { scale: 1; rotate: 0deg; } 33% { scale: 1.03 .97; rotate: 1.5deg; } 66% { scale: .97 1.03; rotate: -1.5deg; } }
@keyframes wt-orbis-blink { 0%, 92%, 98%, 100% { transform: scaleY(1); } 94%, 96% { transform: scaleY(.12); } }
@keyframes wt-orbis-dot { 0%, 60%, 100% { opacity: .35; translate: 0 0; } 30% { opacity: 1; translate: 0 -3px; } }
@keyframes wt-orbis-slide { from { opacity: 0; translate: 12px 0; } }
@keyframes wt-orbis-pop { from { opacity: 0; scale: .97; } }
@keyframes wt-orbis-rise { from { opacity: 0; translate: 0 4px; } }

@media (max-width: 1050px) { body { --wt-orbis-width: 320px; } }
/* On a phone docking does not apply: Boris is a sheet along the bottom (the sheet's rules, below), and made full height
   he fills the workspace. */
@media (max-width: 700px) {
  .wt-orbis-panel, .wt-orbis-panel.is-floating { position: fixed; inset: var(--wt-orbis-top, 60px) 0 0 0 !important; z-index: 40; width: auto !important; height: auto !important; min-width: 0; min-height: 0; max-width: none; max-height: none; border: 0; border-radius: 0; box-shadow: none; resize: none; }
  .wt-orbis-panel .wt-orbis-inner { width: 100%; }
  .wt-orbis-panel .wt-orbis-dock, .wt-orbis-panel .wt-orbis-grip, .wt-orbis-panel .wt-orbis-edge { display: none; }
  .wt-orbis-bar { cursor: default; }
  body button.wt-orbis-orb { right: var(--wt-orb-right, 16px); bottom: var(--wt-orb-bottom, 24px); }
  .wt-orbis-composer textarea.wt-orbis-input { font-size: 16px; }
}
@media (pointer: coarse) { body .wt-orbis-tab button.wt-orbis-tab-close { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .wt-orbis-blob, .wt-orbis-blob.is-large, .wt-orbis-blob.is-thinking, .wt-orb-face i, body button.wt-orbis-orb, body button.wt-orbis-orb::before, .wt-orbis-orb:hover .wt-orbis-blob, .wt-orb-spark, .wt-orbis-blob::before, .wt-orbis-blob.is-booped, .wt-orbis-blob.is-booped .wt-orb-face i, .wt-orbis-inner, .wt-orbis-panel.is-floating .wt-orbis-inner, .wt-orbis-welcome, .wt-orbis-msg.is-new, .wt-orbis-pop, .wt-orbis-typing i { animation: none; }
  .wt-orb-face, body button.wt-orbis-orb, .wt-orbis-panel.is-closing .wt-orbis-inner { transition: none; }
}
/* A picture field in the Edit form: the picture, then upload, choose from the project or remove. */
.wt-boris-image { display:grid; gap:9px; min-width:0; margin:12px 0; }
.wt-boris-generated { display:block; max-width:100%; width:100%; max-height:340px; object-fit:contain; border-radius:var(--r-md); background:var(--wl-surface); }
.wt-boris-image-actions { display:flex; flex-wrap:wrap; gap:6px; }
.wt-boris-image-actions button { font-size:12px; white-space:normal; height:auto; min-height:30px; padding:6px 9px; }
.wt-boris-image-details { color:var(--wl-text-2); font-size:12px; overflow-wrap:anywhere; }
.wt-boris-image-details p { white-space:pre-wrap; }
.wt-orbis-composer-row { flex-wrap:wrap; }
.wt-orbis-composer-row .wt-boris-image-shape { max-width:110px; font-size:12px; height:30px; }
/* Image sits by the +; the model chip (or, while making a picture, the shape) takes the free space. */
body .wt-orbis-composer-row button.wt-orbis-mode.is-image { margin-inline-start: 0; }
.wt-orbis-composer-row .wt-boris-image-shape { margin-inline-end: auto; }
.wt-orbis-composer-row [hidden] { display:none !important; }
.wt-orbis-mode[aria-pressed="true"] { background:var(--wl-raised); color:var(--wl-text); }
/* A file's picture field (D-281): one panel, the picture cropped as its pages crop it (following the focal point),
   its name and folder beside it with the tools under them; the focal point opens inside the same panel. */
.wt-picture-field { display: flex; flex-direction: column; border: 1px solid var(--wl-line); border-radius: var(--r-lg); background: var(--wl-inset); overflow: hidden; }
.wt-picture-input { display: flex; align-items: stretch; gap: 16px; padding: 12px; }
.wt-picture-thumb { flex: none; display: grid; place-items: center; width: 112px; height: 112px; overflow: hidden; border-radius: var(--r-md); background: var(--wl-surface); color: var(--wl-text-3); box-shadow: 0 0 0 1px var(--wl-line); }
.wt-picture-thumb.is-empty { box-shadow: none; border: 1px dashed var(--wl-line-strong); }
.wt-picture-thumb img { width: 100%; height: 100%; object-fit: cover; transition: object-position var(--wl-quick) var(--wl-ease); }
.wt-picture-thumb .wt-glyph svg { width: 26px; height: 26px; stroke-width: 1.5; }
.wt-picture-side { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; min-width: 0; flex: 1; padding: 2px 0; }
.wt-picture-words { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.wt-picture-name { overflow: hidden; color: var(--wl-text); font-size: 14px; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; }
.wt-picture-path { overflow: hidden; color: var(--wl-text-3); font-size: 12px; white-space: nowrap; text-overflow: ellipsis; }
.wt-picture-tools { display: flex; flex-wrap: wrap; gap: 6px; }
.wt-picture-tools button { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 11px; font-size: 12.5px; }
.wt-picture-tools button[hidden] { display: none; }
body.wb-shell .wt-picture-tools button[aria-expanded="true"] { border-color: var(--wl-selection); background: var(--wl-selection-soft); color: var(--wl-text); }
.wt-picture-focus { display: flex; align-items: flex-start; gap: 16px; padding: 12px; border-top: 1px solid var(--wl-line); }
.wt-picture-focus[hidden] { display: none; }
.wt-picture-focus .wt-focus { flex: none; margin: 0; }
.wt-picture-focus .wt-focus img { max-height: 240px; max-width: min(320px, 100%); }
.wt-picture-focus-foot { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0; padding-top: 2px; }
.wt-picture-focus-foot strong { font-size: 13px; font-weight: 600; color: var(--wl-text); }
.wt-picture-focus-foot small { font-size: 12px; line-height: 1.5; }
@media (max-width: 560px) {
  .wt-picture-thumb { width: 88px; height: 88px; }
  .wt-picture-focus { flex-direction: column; }
}
.wt-picture-tools .wt-glyph svg { width: 14px; height: 14px; }
.wt-picture-path { color: var(--wl-text-3); font-size: 11.5px; overflow-wrap: anywhere; }
@media (pointer: coarse) { .wt-picture-tools button { height: 36px; } }

/* Type workspace: the same ink, paper and sage as the rest of Worldrig. */
.wt-ws-body { grid-template-columns: minmax(0,1fr) 336px; }
.wt-ws-bar { min-height:54px; padding-block:9px; gap:16px; background:var(--wl-bg); }
.wt-ws-crumbs { flex:1; }
.wt-ws-title { max-width:240px; }
.wt-ws-actions { margin-inline-start:auto; }
.wt-ws-status { max-width:180px; font-size:11.5px; }
.wt-ws-sync { display:inline-flex; align-items:center; gap:6px; flex-shrink:0; color:var(--wl-selection); font-size:11px; white-space:nowrap; }
.wt-ws-sync::before { content:""; width:5px; height:5px; border-radius:50%; background:currentColor; }
.wt-ws-sync[data-state="pending"] { color:var(--wl-text-3); }
.wt-ws-sync[data-state="error"] { color:var(--wl-danger); }
.wt-ws-stage { background-image:radial-gradient(color-mix(in srgb,var(--wl-line) 65%,transparent) .65px,transparent .65px); background-size:24px 24px; }
.wt-ws-panel { background:var(--wl-inset); }
.wt-ws-band { gap:2px; padding:8px; background:var(--wl-bg); }
.wt-surface .wt-ws-band-tab { display:inline-flex; flex:1; align-items:center; justify-content:center; gap:5px; height:34px; padding:0 7px; background:transparent; color:var(--wl-text-3); font-size:11.5px; border-radius:var(--r-sm); }
.wt-ws-band-tab .wt-glyph { width:14px; height:14px; flex-shrink:0; }
.wt-ws-band .wt-ws-band-tab[aria-selected="true"] { color:var(--wl-text); background:var(--wl-raised); }
.wt-ws-panel-body { padding:8px 18px 96px; scroll-padding-block:16px; }
.wt-ws-panel-head { padding:14px 0 18px; }
.wt-ws-panel-head h3 { margin: 0; font-family: var(--wl-font-title); font-weight: 400; letter-spacing: 0; font-size: var(--t-title-panel); }
.wt-ws-panel-head p { font-size:12px; line-height:1.6; margin-top:7px; color:var(--wl-text-3); }
.wt-ws-section { margin:24px 0 10px; color:var(--wl-text-2); font-size:11px; letter-spacing:.065em; text-transform:uppercase; }
.wt-ws-panel input:not(.wt-switch):not([type="range"]):not([type="color"]), .wt-ws-panel select { min-height:34px; }
.wt-ws-panel :is(input,textarea,select) { border-radius:var(--r-sm); }
.wt-ws-panel .wt-ws-hint { font-size:12px; line-height:1.55; }
.wt-ws input.wt-ws-field-search { width: 100%; margin: 0 0 12px; font-size: 12px; height: 34px; background: var(--wl-inset); }
.wt-ws-field-row { min-height:44px; }
.wt-ws-field-detail { padding-block:12px; }
.wt-ws-start { padding: 32px; box-shadow: var(--wl-elev-card); }
.wt-ws-start h2 { font-family: var(--wl-font-title); font-weight: 400; letter-spacing: 0; font-size: var(--t-title-page); }
.wt-ws-start > p { line-height:1.7; }
.wt-ws-start-footer { flex-wrap:wrap; }
.wt-ws-code { gap:12px; padding:20px; background:var(--wl-inset); }
.wt-ws-code-heading h3 { margin: 0 0 6px; font-family: var(--wl-font-title); font-weight: 400; letter-spacing: 0; font-size: var(--t-title-section); }
.wt-ws-code-heading .wt-ws-hint { line-height:1.6; max-width:54ch; }
.wt-ws-code-bar { flex-shrink:0; }
.wt-ws-code-tools { margin:0; padding:0; flex-wrap:wrap; flex-shrink:0; gap:3px; }
.wt-surface .wt-ws-code-tools .wt-ws-code-tool { height:30px; padding:0 8px; }
.wt-ws-code-surface { display:flex; flex:1 0 260px; min-height:260px; overflow:hidden; border:1px solid var(--wl-line); border-radius:var(--r-md); background:var(--wl-bg); }
.wt-ws-code-surface:focus-within { border-color:var(--wl-selection); box-shadow:0 0 0 1px var(--wl-selection); }
.wt-ws .wt-ws-code-lines { flex:0 0 42px; overflow:hidden; padding:14px 8px; margin:0; border-right:1px solid var(--wl-line); color:var(--wl-text-3); background:var(--wl-inset); text-align:right; user-select:none; font:12px/1.8 var(--wl-font-mono); border-radius:0; }
.wt-ws textarea.wt-ws-code-editor { flex:1; min-width:0; min-height:0; width:0; padding:14px 12px; font:12px/1.8 var(--wl-font-mono); border:0; border-radius:0; background:transparent; box-shadow:none; outline:none; color:var(--wl-text); }
.wt-ws textarea.wt-ws-code-editor:focus { box-shadow:none; border:0; }
.wt-ws-code-footer { display:flex; flex-wrap:wrap; justify-content:space-between; gap:6px 16px; color:var(--wl-text-3); font-size:11px; line-height:1.5; font-variant-numeric:tabular-nums; }
.wt-ws-code-footer [data-state="valid"] { color:var(--wl-selection); }
.wt-ws-code-footer [data-state="error"] { color:var(--wl-danger); }
.wt-ws .wt-ws-code-error { padding:10px 12px; border:1px solid var(--wl-danger); border-radius:var(--r-sm); font-size:12px; line-height:1.6; overflow-wrap:anywhere; }
.wt-ws-code-guide { grid-template-columns:minmax(0,1fr); gap:4px; }
.wt-ws-code-guide dd { margin-bottom:9px; }
.wt-ws-code-guide code { white-space:normal; overflow-wrap:anywhere; }
.wt-ws :is(button,summary,select):focus-visible { outline:2px solid var(--wl-selection); outline-offset:2px; }
@container wt-ws (min-width:800px) {
  .wt-ws.is-code .wt-ws-body { grid-template-columns:minmax(350px,48%) minmax(0,1fr); }
}
@container wt-ws (max-width:979px) {
  .wt-ws-view > span:last-child { position:static; width:auto; height:auto; clip-path:none; white-space:nowrap; }
  .wt-ws-bar { gap:8px; }
  .wt-ws-status { max-width:100px; }
  .wt-ws-title { max-width:160px; }
  .wt-ws-sync { font-size:10px; }
}
@container wt-ws (max-width:799px) {
  .wt-ws-body { grid-template-columns:minmax(0,1fr); }
  .wt-ws-panel { width:min(360px,94%); }
  .wt-ws.is-code .wt-ws-body { grid-template-rows:minmax(320px,1fr) minmax(180px,35%); }
  .wt-ws-code { padding:16px; }
  .wt-ws-code-surface { flex-basis:180px; min-height:180px; }
}
@container wt-ws (max-width:599px) {
  .wt-ws-bar { flex-wrap:wrap; align-items:center; justify-content:space-between; gap:8px 10px; padding:10px 12px; }
  .wt-ws-crumbs { order:1; flex:1 1 auto; min-width:0; }
  .wt-ws-title { max-width:100%; font-size:14.5px; }
  .wt-ws-actions { order:2; flex:0 0 auto; margin-inline-start:auto; gap:6px; }
  .wt-ws-views { order:3; flex:0 1 auto; }
  .wt-ws-sync { order:4; margin-inline-start:auto; font-size:11px; }
  .wt-ws-save { min-width:60px; }
  .wt-ws-panel { width:auto; height:min(78%,660px); }
  .wt-ws-band { padding-right:8px; }
  .wt-ws-band-tab .wt-glyph { display:none; }
  .wt-ws-panel-body { padding-inline:14px; }
  .wt-ws-code-surface { flex-basis:150px; min-height:150px; }
}
@container wt-ws (max-width:380px) {
  .wt-ws-views { flex:1 1 100%; }
  .wt-ws-views .wt-ws-view { flex:1 1 0; justify-content:center; }
  .wt-ws-sync { margin-inline-start:0; }
}

@container wt-ws (min-width:800px){.wt-ws .wt-ws-panel-toggle,.wt-ws .wt-ws-panel-close{display:none;}}


/* A document has one writing surface and a compact set of supporting properties. */
.wt-document, .wt-document-form { min-width:0; }
/* A document's picture is its cover, over the title (2026-11-03). */
/* A document's header (D-275): its picture fills it with the type, the title and the description over its foot,
   white on a shade rising from the bottom, as a card's header (D-272); without a picture, the same words on the page. */
.wt-document-head { position:relative; margin:0 0 26px; }
.wt-document.has-cover .wt-document-head { isolation:isolate; overflow:hidden; display:flex; flex-direction:column; justify-content:flex-end; box-sizing:border-box; min-height:clamp(260px, 44cqi, 440px); padding:clamp(110px, 20cqi, 190px) 32px 28px; border-radius:var(--r-xl); color:#fff; background:#0b0e16; }
.wt-document.has-cover .wt-document-head::after { content:""; position:absolute; inset:0; z-index:-1; background:linear-gradient(to top, rgb(5 8 16 / .9) 0%, rgb(5 8 16 / .62) 38%, rgb(5 8 16 / .24) 66%, transparent 88%); pointer-events:none; }
.wt-document-cover { position:absolute; inset:0; z-index:-2; display:block; width:100%; height:100%; object-fit:cover; object-position:50% 30%; }
.wt-document-eyebrow { margin:0 0 10px; color:var(--wl-text-3); font-size:10px; font-weight:600; letter-spacing:.12em; text-transform:uppercase; }
.wt-document-title { margin:0; font-family: var(--wl-font-title); font-weight: 400; letter-spacing: 0; font-size: var(--t-title-page); line-height: 1.25; overflow-wrap: anywhere; }
.wt-document-lead { max-width:62ch; margin:12px 0 0; color:var(--wl-text-2); font-size:16px; line-height:1.6; }
.wt-document-lead > :first-child { margin-top:0; } .wt-document-lead > :last-child { margin-bottom:0; }
.wt-document.has-cover .wt-document-eyebrow { color:rgb(255 255 255 / .78); }
.wt-document.has-cover .wt-document-title { color:#fff; text-shadow:0 2px 18px rgb(0 0 0 / .5); }
.wt-document.has-cover .wt-document-lead { color:rgb(255 255 255 / .88); text-shadow:0 1px 12px rgb(0 0 0 / .5); }
@container (max-width:520px) { .wt-document.has-cover .wt-document-head { min-height:clamp(300px, 100cqi, 440px); padding:clamp(100px, 36cqi, 170px) 18px 18px; border-radius:var(--r-md); } .wt-document-lead { font-size:14.5px; } }
/* What it is linked to and its other facts, in the open: a name on the left, linked files as names that open them. */
.wt-document-facts { display:grid; gap:12px; margin:0 0 30px; padding:16px 0; border-block:1px solid var(--wl-line); }
.wt-document-facts > div { display:grid; grid-template-columns:minmax(90px, 24%) minmax(0, 1fr); gap:16px; align-items:baseline; }
.wt-document-facts dt { color:var(--wl-text-2); font-size:12px; }
.wt-document-facts dd { display:flex; flex-wrap:wrap; gap:6px; margin:0; font-size:13.5px; overflow-wrap:anywhere; }
.wt-document-facts dd.is-writing { display:block; } .wt-document-facts dd.is-writing > :first-child { margin-top:0; } .wt-document-facts dd.is-writing > :last-child { margin-bottom:0; }
body.wb-shell .wt-document-link { height:auto; min-height:0; padding:3px 11px; border:0; border-radius:999px; font-size:12.5px; font-weight:500; color:var(--wl-text); background:var(--wl-raised); box-shadow:inset 0 0 0 1px var(--wl-line); cursor:pointer; transition:box-shadow var(--wl-quick) var(--wl-ease); }
body.wb-shell .wt-document-link:hover { box-shadow:inset 0 0 0 1px var(--wl-line-strong); }
@container (max-width:420px) { .wt-document-facts > div { grid-template-columns:1fr; gap:6px; } }
.wt-document-properties { margin:0 0 26px; border-block:1px solid var(--wl-line); }
.wt-document-properties > summary { padding:13px 2px; color:var(--wl-text-2); font-size:12px; cursor:pointer; }
.wt-document-fields { padding:0 8px 12px; }
.wt-document-editor { border:1px solid var(--wl-line); border-radius:var(--r-lg); overflow:hidden; background:var(--wl-bg); }
.wt-document-editor-head { display:flex; align-items:center; flex-wrap:wrap; gap:10px; padding:12px 16px; border-bottom:1px solid var(--wl-line); }
.wt-document-editor-head label { color:var(--wl-text); font-weight:600; font-size:13px; }
.wt-document-format { color:var(--wl-text-3); font-size:10px; }
.wt-document-editor-head .wt-segment { margin-left:auto; }
.wt-document-editor-head .wt-segment button { font-size:11px; height:28px; }
.wt-document-toolbar { display:flex; flex-wrap:wrap; gap:2px; padding:8px 12px; border-bottom:1px solid var(--wl-line); }
.wt-document-toolbar button { height:28px; width:30px; padding:6px; border:0; border-radius:var(--r-sm); background:transparent; box-shadow:none; color:var(--wl-text-2); }
.wt-document-toolbar button:hover { background:var(--wl-raised); color:var(--wl-text); }
.wt-document-toolbar button > span:last-child { display:none; }
.wt-document-input { display:block; width:100%; min-height:380px; padding:22px; border:0; border-radius:0; background:transparent; box-shadow:none; resize:vertical; font-family:var(--wl-font-ui); font-size:15px; line-height:1.85; color:var(--wl-text); }
.wt-document-input:focus { box-shadow:inset 3px 0 0 var(--wl-selection); }
/* The writing in the theme's story face (D-268), its headings in the interface face: plain, a step apart. */
.wt-document-prose { font-family:var(--wl-font-reading, var(--wl-font-ui)); font-size:17px; line-height:1.75; overflow-wrap:anywhere; }
body.wb-shell .wt-document-prose :is(h1, h2, h3, h4, h5, h6) { margin:1.7em 0 .55em; font-family:var(--wl-font-ui); font-weight:700; letter-spacing:-.01em; text-transform:none; line-height:1.3; color:var(--wl-text); }
body.wb-shell .wt-document-prose h1 { font-size:26px; } body.wb-shell .wt-document-prose h2 { font-size:21px; } body.wb-shell .wt-document-prose h3 { font-size:17.5px; } body.wb-shell .wt-document-prose :is(h4, h5, h6) { font-size:15px; }
.wt-document-editor > .wt-document-prose { font-size:16px; }
.wt-document-prose > :first-child { margin-top:0; }
.wt-document-editor > .wt-document-prose { min-height:380px; padding:22px; }
.wt-document-prose img { max-width:100%; }
.wt-document-prose pre { max-width:100%; overflow:auto; }
.wt-document-prose table { display:block; max-width:100%; overflow:auto; }
.wt-document-prose blockquote { margin-left: 0; padding-left: 20px; border-left: 2px solid var(--wl-line-strong); color: var(--wl-text-2); }
.wt-document-empty { padding:28px 0; color:var(--wl-text-3); font-size:14px; }
.wt-document-editor-foot { display:flex; flex-wrap:wrap; justify-content:space-between; gap:8px; padding:10px 16px; border-top:1px solid var(--wl-line); color:var(--wl-text-3); font-size:10px; }
.wt-document-editor [hidden] { display:none !important; }

/* ---- The Page view, redesigned (D-111): Add and On the page on the left, the page with its
   own floating bar in the middle, what is selected on the right. Play is its own view. ---- */
.wt-ws.is-design .wt-ws-body { grid-template-columns: 268px minmax(0, 1fr) 332px; --wt-ws-side-drawer: 0; }
.wt-ws.is-play .wt-ws-body { display: block; }
.wt-ws.is-starting .wt-ws-side, .wt-ws.is-starting .wt-ws-pbar { display: none; }
.wt-ws.is-starting.is-design .wt-ws-body { grid-template-columns: minmax(0, 1fr); }

/* The left column */
.wt-ws-side { position: relative; min-width: 0; min-height: 0; display: flex; flex-direction: column; background: var(--wl-inset); border-right: 1px solid var(--wl-line); }
/* Its two tabs are the editor's rail (the right column's rules, D-270). */
.wt-ws-side-tabs { margin: 10px 14px 6px; }
.wt-surface .wt-ws-side .wt-ws-side-close { display: none; }
.wt-ws-side-body { flex: 1; min-height: 0; overflow: auto; padding: 8px 12px 40px; }
.wt-ws input.wt-ws-side-search { width: 100%; height: 34px; margin: 0 0 4px; font-size: 12.5px; background: var(--wl-inset); border-radius: var(--r-md); }
.wt-ws-add-title { margin: 18px 4px 8px; color: var(--wl-text-3); font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.wt-ws-add-list { display: flex; flex-direction: column; gap: 4px; }
.wt-ws-add-group.is-grid .wt-ws-add-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
/* Two to a row the names have a little more room, so "Linked cards" fits */
.wt-surface .wt-ws-add-group.is-grid .wt-ws-add-item { gap: 7px; padding-right: 7px; }
.wt-surface .wt-ws-add-item { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; height: 36px; padding: 0 10px; border-radius: var(--r-md); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text); font-size: 12.5px; font-weight: 400; text-align: left; justify-content: flex-start; cursor: grab; touch-action: none; transition: background-color var(--wl-quick) var(--wl-ease), box-shadow var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-ws-add-item:hover { background: var(--wl-raised); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-surface .wt-ws-add-item.is-selected { background: var(--wl-selection-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 45%, transparent); }
.wt-ws-add-item .wt-glyph { width: 15px; height: 15px; flex-shrink: 0; color: var(--wl-text-2); }
.wt-ws-add-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-ws-add-item .wt-ws-reach-chip { padding: 0 7px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); color: var(--wl-text-3); font-size: 10.5px; line-height: 17px; }
.wt-ws-add-item .wt-ws-reach-chip::before { display: none; }
.wt-surface .wt-ws-add-item.is-more { cursor: pointer; background: transparent; box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); }
/* A field not on the page is cleared from its row (D-131): the button takes the reach chip's place
   while the row is pointed at or in focus; on a touch screen it always shows, beside the chip. */
.wt-ws-add-row { position: relative; }
.wt-ws-add-row:has(> .wt-ws-add-item[hidden]) { display: none; }
.wt-surface .wt-ws-add-row .wt-ws-add-clear { position: absolute; top: 50%; right: 5px; width: 26px; height: 26px; translate: 0 -50%; border-radius: var(--r-md); background: transparent; color: var(--wl-text-3); opacity: 0; transition: opacity var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease), background-color var(--wl-quick) var(--wl-ease); }
.wt-ws-add-row .wt-ws-add-clear .wt-glyph { width: 14px; height: 14px; }
.wt-ws-add-row:is(:hover, :focus-within) .wt-ws-add-clear { opacity: 1; }
.wt-ws-add-row:is(:hover, :focus-within) .wt-ws-reach-chip { visibility: hidden; }
.wt-surface .wt-ws-add-row .wt-ws-add-clear:is(:hover, :focus-visible) { background: var(--wl-line); color: var(--wl-text); }
@media (hover: none) { .wt-ws-add-row .wt-ws-add-clear { opacity: 1; } .wt-ws-add-row .wt-ws-reach-chip, .wt-ws-add-row:is(:hover, :focus-within) .wt-ws-reach-chip { visibility: visible; margin-right: 30px; } }
.wt-ws-add-empty { margin: 16px 4px; }
.wt-ws-add-help, .wt-ws-side-note { margin: 16px 4px 0; color: var(--wl-text-3); font-size: 12px; line-height: 1.55; }
.wt-ws-side-note { margin: -2px 4px 8px; }
.wt-ws-side .wt-ws-layers { margin: 2px -4px 0; }
.wt-surface .wt-ws-side .wt-ws-layer { border-radius: var(--r-md); font-size: 12.5px; }
.wt-surface .wt-ws-side .wt-ws-layer.is-selected { background: var(--wl-selection-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 40%, transparent); }
.wt-ws-side .wt-ws-hidden { margin-top: 18px; color: var(--wl-text-3); font-size: 12px; }
/* A part dragged from the left column: its name follows the pointer, and says where it lands. */
.wt-ws-add-ghost { position: fixed; z-index: 10000; display: flex; align-items: center; gap: 8px; max-width: 360px; padding: 7px 12px 7px 10px; border-radius: var(--r-md); background: var(--wl-raised); box-shadow: 0 0 0 2px var(--wl-selection), var(--wl-elev-pop); color: var(--wl-text); font-size: 12.5px; font-weight: 500; pointer-events: none; transform: rotate(-1.5deg); }
.wt-ws-add-ghost .wt-glyph { width: 15px; height: 15px; color: var(--wl-text-2); flex-shrink: 0; }
.wt-ws-add-ghost small { padding: 1px 8px; border-radius: var(--r-pill); background: var(--wl-selection); color: var(--wl-on-accent); font-size: 11px; font-weight: 600; white-space: nowrap; }
.wt-ws.is-adding .wt-ws-custom-page iframe { pointer-events: none; }

/* The page's own floating bar */
.wt-ws-pbar { position: absolute; top: 14px; left: 50%; z-index: 5; transform: translateX(-50%); display: flex; align-items: center; gap: 2px; max-width: calc(100% - 24px); height: 42px; padding: 0 5px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: var(--wl-elev-pop); overflow-x: auto; scrollbar-width: none; }
.wt-ws-pbar-group { display: flex; align-items: center; gap: 1px; }
.wt-ws-pbar-sep { flex: none; width: 1px; height: 20px; margin: 0 4px; background: var(--wl-line); }
.wt-ws-pbar .wt-icon-button { width: 32px; height: 32px; border-radius: var(--r-pill); color: var(--wl-text-2); }
.wt-ws-pbar .wt-icon-button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); }
.wt-surface .wt-ws-pbar-who, .wt-surface .wt-ws-pbar-see { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 10px 0 5px; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.wt-surface .wt-ws-pbar-see { padding: 0 10px; color: var(--wl-text-2); }
.wt-surface .wt-ws-pbar-who:hover, .wt-surface .wt-ws-pbar-see:hover { background: var(--wl-raised); }
/* The file the page is shown with: its picture as a small round face with a thin ring (a portrait
   elsewhere is a tall box, so its height and edge are set again here) */
.wt-ws-pbar-who .wt-portrait { flex: none; width: 24px; height: 24px; min-width: 24px; min-height: 0; border: 0; border-radius: 50%; overflow: hidden; background: var(--wl-raised); box-shadow: 0 0 0 1px var(--wl-line-strong); }
.wt-ws-pbar-who .wt-portrait img { width: 100%; height: 100%; object-fit: cover; transition: opacity var(--wl-quick) var(--wl-ease); }
.wt-ws-pbar-who .wt-portrait img.is-loading { opacity: 0; }
body.wb-shell .wt-ws-pbar-who .wt-portrait .wl-emblem-art:not(.is-small) { display: none; }
body.wb-shell .wt-ws-pbar-who .wt-portrait .wl-emblem-art.is-small { display: block; }
.wt-ws-pbar-who > .wt-glyph:first-child { width: 15px; height: 15px; margin-left: 5px; color: var(--wl-text-2); }
.wt-ws-pbar :is(.wt-ws-pbar-who, .wt-ws-pbar-see) .wt-glyph:last-child { width: 13px; height: 13px; color: var(--wl-text-3); }
.wt-ws-pbar-see .wt-glyph:first-child { width: 15px; height: 15px; }
.wt-ws-pbar-see b { color: var(--wl-text); font-weight: 600; }
.wt-surface .wt-ws-pbar-see[aria-pressed="true"] { background: var(--wl-selection-soft); color: var(--wl-text); }
.wt-ws-pbar-note { padding: 0 8px; color: var(--wl-text-3); font-size: 11.5px; white-space: nowrap; }
/* Every button of the bar stays in view (D-270): it scrolled sideways out of sight and cut off Redo.
   As the page narrows it lets go of words first, then the file's name, then the widths. */
.wt-ws.is-design .wt-ws-stage { container: wt-stage / inline-size; }
@container wt-stage (max-width: 660px) { .wt-ws-pbar-dim { display: none; } }
@container wt-stage (max-width: 560px) {
  .wt-ws-pbar-who > span:not(.wt-glyph):not(.wt-portrait) { display: none; }
  .wt-surface .wt-ws-pbar-who { padding-right: 8px; }
}
@container wt-stage (max-width: 440px) { .wt-ws-pbar-widths, .wt-ws-pbar-sep:has(+ .wt-ws-pbar-widths) { display: none; } }
.wt-ws.is-design .wt-ws-scroll { padding: 78px 36px 72px; }
.wt-ws-stage.is-preview .wt-ws-scroll { padding: 72px 20px 40px; }
.wt-ws-chips, .wt-ws-controls, .wt-ws-dock { display: none !important; }

/* The right column */
.wt-ws.is-design .wt-ws-panel { border-left: 1px solid var(--wl-line); }

/* Play: how a game treats the type, as its own view (D-146, made short 2026-11-18). One column of named parts on
   the sheet: a micro-label on a line, then rows. The card as a game shows it is Page's Game preview. */
.wt-ws-play-scroll { height: 100%; overflow: auto; padding: 32px 24px 80px; }
.wt-ws-play-grid { max-width: 720px; margin: 0 auto; }
.wt-ws-play { min-width: 0; }
.wt-ws-play .wt-ws-panel-body { display: flex; flex-direction: column; gap: 34px; padding: 0; }
.wt-play-sec { display: grid; gap: 12px; min-width: 0; }
.wt-play-sec-head { display: flex; align-items: center; gap: 14px; min-height: 28px; }
.wt-play-sec-head h4 { margin: 0; color: var(--wl-text-2); font: 600 11px/1.2 var(--wl-font-ui); letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; cursor: default; }
.wt-play-sec-head::after { content: ""; order: 1; flex: 1; height: 1px; background: color-mix(in srgb, var(--wl-text) 9%, transparent); }
.wt-surface .wt-play-sec-head > .wt-play-link { order: 2; margin: 0; }
.wt-play-says { margin: 0; color: var(--wl-text-3); font-size: 13px; line-height: 1.5; }
/* What it is: one row of pills. */
.wt-play-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.wt-surface .wt-play-pill { display: inline-flex; align-items: center; gap: 8px; width: auto; height: 36px; margin: 0; padding: 0 16px 0 13px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-text) 12%, transparent); color: var(--wl-text-2); font: 500 13.5px var(--wl-font-ui); cursor: pointer; }
.wt-play-pill .wt-glyph, .wt-play-pill svg { width: 15px; height: 15px; }
.wt-surface .wt-play-pill:hover { background: color-mix(in srgb, var(--wl-text) 5%, transparent); color: var(--wl-text); }
.wt-surface .wt-play-pill.is-on { background: var(--wl-selection-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 60%, transparent); color: var(--wl-text); font-weight: 600; }
/* What it can do: the mechanics on it as rows, each opening in Mechanics; Messages under them. */
.wt-play-list { display: grid; }
.wt-play-list:empty { display: none; }
.wt-surface .wt-play-item { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; height: auto; min-height: 58px; margin: 0; padding: 10px 6px; border: 0; border-top: 1px solid color-mix(in srgb, var(--wl-text) 7%, transparent); border-radius: 0; background: transparent; box-shadow: none; color: var(--wl-text); text-align: left; cursor: pointer; }
.wt-play-list > :last-child { border-bottom: 1px solid color-mix(in srgb, var(--wl-text) 7%, transparent); }
.wt-surface .wt-play-item:hover { background: color-mix(in srgb, var(--wl-text) 4%, transparent); }
.wt-play-item > span:empty { display: none; }
.wt-play-item-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: color-mix(in srgb, var(--wl-text) 6%, transparent); color: var(--wl-text-2); }
.wt-surface .wt-play-item-icon :is(.wt-glyph, svg) { display: block; width: 16px; height: 16px; }
.wt-play-item-words { display: grid; gap: 2px; min-width: 0; }
.wt-play-item-words b { font-size: 14px; font-weight: 600; }
.wt-play-item-words small { overflow: hidden; color: var(--wl-text-3); font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.wt-play-item > .wt-glyph:last-child { width: 14px; height: 14px; color: var(--wl-text-3); }
.wt-play-list > .wt-play-action { padding: 4px 6px 12px; border-top: 1px solid color-mix(in srgb, var(--wl-text) 7%, transparent); border-radius: 0; box-shadow: none; }
.wt-play-list > .wt-play-action + .wt-play-action { margin-top: 0; }
.wt-surface .wt-play-sec > .wt-play-add { justify-self: start; margin: 0; }
/* For the GM: each setting a row, its name left and its control right. */
.wt-play-set { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 14px 6px; border-top: 1px solid color-mix(in srgb, var(--wl-text) 7%, transparent); }
.wt-play-set-words { display: grid; gap: 3px; min-width: 0; }
.wt-play-set-words b { color: var(--wl-text); font-size: 13.5px; font-weight: 600; cursor: default; }
.wt-play-set-words small { color: var(--wl-text-3); font-size: 12.5px; line-height: 1.45; }
.wt-play-set > :is(.wt-ws-segment, select) { flex: none; }
.wt-play-set > select { width: 200px; min-height: 34px; }
/* The same size as Code's heading: both name the view beside the page (D-270). */
.wt-play-head h3 { margin: 0; font: 400 var(--t-title-section)/1.35 var(--wl-font-title); letter-spacing: 0; }
.wt-play-head p { margin: 6px 0 8px; color: var(--wl-text-3); font-size: 13px; line-height: 1.5; }
.wt-ws-play .wt-ws-card.wt-play-card { margin: 0; padding: 14px 16px 16px; }
.wt-play-card .wt-ws-card-head { margin-bottom: 2px; }
.wt-play-line { margin: 0 0 12px; color: var(--wl-text-3); font-size: 12.5px; line-height: 1.5; }
.wt-play-card > .wt-ws-segment + .wt-play-line { margin: 10px 0 0; }
.wt-play-foot { margin: 10px 0 0; color: var(--wl-text-3); font-size: 12px; line-height: 1.5; }
.wt-ws-play .wt-inline-error { margin: 6px 0 0; }
/* Tiles, choices and the add tile are buttons drawn as cards inside the card. */
.wt-surface :is(.wt-play-role, .wt-play-choice, .wt-play-add) { position: relative; display: grid; width: 100%; height: auto; margin: 0; padding: 11px 12px; border: 0; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text); font: inherit; text-align: left; white-space: normal; cursor: pointer; transition: background-color var(--wl-quick) var(--wl-ease), box-shadow var(--wl-quick) var(--wl-ease); }
/* The button helper's own label (empty here) takes no cell. */
:is(.wt-play-role, .wt-play-choice, .wt-play-add) > span:empty { display: none; }
.wt-surface :is(.wt-play-role, .wt-play-choice, .wt-play-add):hover { background: color-mix(in srgb, var(--wl-raised) 60%, var(--wl-inset)); }
.wt-surface :is(.wt-play-role, .wt-play-choice).is-on { background: var(--wl-selection-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 60%, transparent); }
:is(.wt-play-role, .wt-play-choice, .wt-play-add) b { font-size: 13.5px; font-weight: 600; }
:is(.wt-play-role, .wt-play-choice, .wt-play-add) small { color: var(--wl-text-3); font-size: 12px; line-height: 1.4; }
.wt-play-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r-md); background: var(--wl-raised); color: var(--wl-text-2); }
.wt-play-icon .wt-glyph, .wt-play-icon svg { width: 16px; height: 16px; }
.wt-play-roles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.wt-surface .wt-play-role { grid-template-columns: 34px minmax(0, 1fr); gap: 1px 11px; align-items: center; padding-right: 34px; }
.wt-play-role .wt-play-icon { grid-row: 1 / span 2; }
.wt-play-role b, .wt-play-role small { grid-column: 2; }
.wt-play-role.is-on .wt-play-icon { background: color-mix(in srgb, var(--wl-selection) 16%, transparent); color: var(--wl-selection); }
.wt-play-tick { position: absolute; top: 9px; right: 9px; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--wl-selection); color: var(--wl-inset); }
.wt-play-tick svg { width: 12px; height: 12px; stroke-width: 2.5; }
.wt-play-gives { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; color: var(--wl-text-3); font-size: 12px; }
.wt-play-chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px 3px 7px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text-2); }
.wt-play-chip .wt-glyph, .wt-play-chip svg { width: 12px; height: 12px; color: var(--wl-success); stroke-width: 2.25; }
.wt-play-note { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 12px; padding: 10px 12px; border-radius: var(--r-md); background: var(--wl-inset); color: var(--wl-text-2); font-size: 12.5px; line-height: 1.5; }
.wt-play-note p { margin: 0; flex: 1 1 260px; }
.wt-play-row { display: flex; align-items: center; gap: 16px; padding: 10px 0; }
.wt-play-row + .wt-play-row { border-top: 1px solid var(--wl-line); }
.wt-play-row > div { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.wt-play-row b { font-size: 13px; font-weight: 500; }
.wt-play-row small { color: var(--wl-text-3); font-size: 12px; line-height: 1.4; }
.wt-play-row select { flex: none; width: 210px; min-height: 34px; }
.wt-play-now { display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 8px; align-items: start; margin-top: 4px; padding: 8px 10px; border-radius: var(--r-md); background: var(--wl-inset); color: var(--wl-text-3); font-size: 12px; line-height: 1.45; }
.wt-play-now .wt-glyph, .wt-play-now svg { width: 14px; height: 14px; margin-top: 1px; }
.wt-play-now b { color: var(--wl-text-2); font-weight: 500; }
.wt-surface .wt-play-link { display: inline-flex; align-items: center; gap: 6px; width: auto; height: 28px; margin: 6px 0 0; padding: 0 2px; border: 0; background: none; box-shadow: none; color: var(--wl-selection); font-size: 12.5px; white-space: nowrap; }
.wt-play-row .wt-play-link { margin: 0; }
.wt-surface .wt-play-link:hover { color: var(--wl-text); background: none; }
.wt-play-link .wt-glyph, .wt-play-link svg { width: 14px; height: 14px; }
.wt-play-choices { display: flex; flex-direction: column; gap: 6px; }
.wt-surface .wt-play-choice { grid-template-columns: 18px minmax(0, 1fr); gap: 1px 11px; padding: 10px 12px; }
.wt-play-choice i { grid-row: 1 / span 2; width: 16px; height: 16px; margin-top: 1px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--wl-line-strong); transition: box-shadow var(--wl-quick) var(--wl-ease); }
.wt-play-choice b { font-size: 13px; font-weight: 500; }
.wt-play-choice b, .wt-play-choice small { grid-column: 2; }
.wt-play-choice.is-on i { box-shadow: inset 0 0 0 5px var(--wl-selection); }
.wt-surface .wt-play-add { grid-template-columns: 34px minmax(0, 1fr) auto; gap: 1px 11px; align-items: center; }
.wt-play-add .wt-play-icon { grid-column: 1; grid-row: 1 / span 2; }
.wt-play-add b, .wt-play-add small { grid-column: 2; }
.wt-play-add-go { grid-column: 3; grid-row: 1 / span 2; display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: var(--r-pill); background: var(--wl-raised); font-size: 12.5px; font-weight: 500; }
.wt-play-add-go .wt-glyph, .wt-play-add-go svg { width: 14px; height: 14px; }
.wt-play-action { padding: 4px 14px 12px; border-radius: var(--r-md); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-play-action + .wt-play-action { margin-top: 8px; }
.wt-play-action-head { display: flex; align-items: center; gap: 10px; padding: 8px 0 4px; }
.wt-play-action-head .wt-play-icon { width: 30px; height: 30px; border-radius: var(--r-md); flex: none; }
.wt-surface .wt-play-action-head input { flex: 1; min-width: 0; height: 32px; padding: 0 8px; border: 0; border-radius: var(--r-md); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 14px; font-weight: 600; }
.wt-surface .wt-play-action-head input:hover, .wt-surface .wt-play-action-head input:focus { background: var(--wl-inset); }
.wt-play-action-head .wt-icon-button { color: var(--wl-text-3); }
.wt-play-placed { display: inline-flex; align-items: center; gap: 6px; color: var(--wl-text-2); font-size: 12.5px; }
.wt-play-placed .wt-glyph, .wt-play-placed svg { width: 14px; height: 14px; color: var(--wl-success); stroke-width: 2.25; }
.wt-play-chat { display: grid; gap: 8px; margin-top: 8px; padding: 12px; border-radius: var(--r-md); background: var(--wl-inset); font-size: 12.5px; }
.wt-play-chat-label { color: var(--wl-text-3); font-size: 11px; }
.wt-play-chat-who { display: flex; align-items: center; justify-content: space-between; padding: 7px 10px; border-radius: var(--r-md); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); }
.wt-play-chat-who .wt-glyph, .wt-play-chat-who svg { width: 14px; height: 14px; }
.wt-play-bubble { justify-self: end; max-width: 80%; padding: 7px 11px; border-radius: var(--r-md) var(--r-md) var(--r-xs) var(--r-md); background: color-mix(in srgb, var(--wl-accent) 12%, var(--wl-surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-accent) 45%, transparent); color: var(--wl-text-2); }
.wt-play-bubble.is-reply { justify-self: start; border-radius: var(--r-md) var(--r-md) var(--r-md) var(--r-xs); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-play-chat-write { display: flex; gap: 8px; align-items: center; }
.wt-play-chat-write span { flex: 1; padding: 8px 10px; border-radius: var(--r-md); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-3); }
.wt-play-chat-write em { padding: 7px 12px; border-radius: var(--r-md); background: var(--wl-accent); color: var(--wl-on-accent); font-style: normal; font-weight: 600; }
/* What it can do (D-150): a type's scripts as sentences that open to When, It changes and Not when;
   the box to say a new one; under the card, what pressing a button did to a copy. */
.wt-sc { display: flex; flex-direction: column; gap: 8px; }
.wt-sc:empty { display: none; }
.wt-sc-row { border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); transition: box-shadow var(--wl-quick) var(--wl-ease); }
.wt-sc-row:is(.is-open, .is-working) { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 45%, var(--wl-line)); }
.wt-surface .wt-sc-head { box-sizing: border-box; display: grid; grid-template-columns: 34px minmax(0, 1fr) auto 16px; gap: 12px; align-items: center; width: 100%; height: auto; margin: 0; padding: 11px 12px; border: 0; border-radius: var(--r-md); background: none; box-shadow: none; color: var(--wl-text); text-align: left; font: inherit; cursor: pointer; }
.wt-sc-row.is-working .wt-sc-head { grid-template-columns: 34px minmax(0, 1fr); cursor: default; }
.wt-sc-head > span:empty { display: none; }
.wt-surface .wt-sc-head:hover { background: none; }
.wt-surface .wt-sc-head:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: -2px; }
.wt-sc-head .wt-play-icon { align-self: start; }
.wt-sc-words { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.wt-sc-words b { font-size: 13.5px; font-weight: 600; }
.wt-sc-words small { color: var(--wl-text-3); font-size: 12.5px; line-height: 1.45; white-space: normal; }
.wt-sc-row.is-working .wt-sc-words small { color: var(--wl-text-2); }
.wt-sc-new { margin-left: 8px; padding: 1px 7px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--wl-selection) 18%, transparent); color: var(--wl-selection); font-size: 10.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; vertical-align: 1px; }
.wt-sc-start { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 11px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text-2); font-size: 12.5px; white-space: nowrap; }
.wt-sc-start .wt-glyph, .wt-sc-start svg { width: 14px; height: 14px; color: var(--wl-text-3); }
.wt-sc-chev { display: flex; color: var(--wl-text-3); }
.wt-sc-chev .wt-glyph, .wt-sc-chev svg { width: 15px; height: 15px; }
.wt-sc-spin { display: block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--wl-selection) 30%, transparent); border-top-color: var(--wl-selection); animation: wt-sc-spin .8s linear infinite; }
@keyframes wt-sc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .wt-sc-spin { animation-duration: 2.4s; } }
.wt-sc-detail { display: flex; flex-direction: column; padding: 0 12px 12px 58px; animation: wt-sc-open .18s ease-out; }
@keyframes wt-sc-open { from { opacity: 0; transform: translateY(-3px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .wt-sc-detail, .wt-sc-try { animation: none; } }
.wt-sc-line { display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: 12px; padding: 9px 0; border-top: 1px solid var(--wl-line); color: var(--wl-text-2); font-size: 13px; line-height: 1.5; }
.wt-sc-k { padding-top: 1px; color: var(--wl-text-3); font-size: 12px; }
.wt-sc-how { display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: 12px; align-items: center; padding: 9px 0; border-top: 1px solid var(--wl-line); }
.wt-sc-how .wt-ws-segment { max-width: 420px; }
.wt-sc-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.wt-sc-chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text); font-size: 12.5px; }
.wt-sc-chip .wt-glyph, .wt-sc-chip svg { width: 13px; height: 13px; color: var(--wl-text-3); }
.wt-sc-tried { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 10px; margin-top: 4px; padding: 10px 12px; border-radius: var(--r-md); background: color-mix(in srgb, var(--wl-success) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-success) 20%, transparent); color: var(--wl-text-2); font-size: 12.5px; line-height: 1.5; }
.wt-sc-tried > .wt-glyph, .wt-sc-tried > svg { width: 15px; height: 15px; margin-top: 2px; color: var(--wl-success); }
.wt-sc-tried.is-wrong { background: color-mix(in srgb, var(--wl-danger) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-danger) 22%, transparent); }
.wt-sc-tried.is-wrong > .wt-glyph, .wt-sc-tried.is-wrong > svg { color: var(--wl-danger); }
.wt-sc-tried b { color: var(--wl-text); font-weight: 600; }
.wt-sc-detail > .wt-play-row { margin-top: 8px; padding: 10px 0 0; border-top: 1px solid var(--wl-line); }
.wt-sc-detail > .wt-inline-error { margin: 4px 0 6px; }
.wt-sc-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; }
.wt-sc-gap { flex: 1; }
.wt-surface .wt-sc-btn { display: inline-flex; align-items: center; gap: 7px; height: 30px; margin: 0; padding: 0 12px; border: 0; border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: none; color: var(--wl-text); font-size: 12.5px; font-weight: 500; white-space: nowrap; cursor: pointer; }
.wt-surface .wt-sc-btn:hover { background: color-mix(in srgb, var(--wl-raised) 85%, var(--wl-text)); }
.wt-surface .wt-sc-btn.is-quiet { background: transparent; color: var(--wl-text-3); }
.wt-surface .wt-sc-btn.is-quiet:hover { background: var(--wl-raised); color: var(--wl-text); }
.wt-sc-btn .wt-glyph, .wt-sc-btn svg { width: 14px; height: 14px; }
.wt-sc-more { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; margin-top: 10px; }
.wt-sc-more small { color: var(--wl-text-3); font-size: 12px; }
.wt-sc-ask { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 12px; align-items: center; margin: 10px 0 0; padding: 8px 8px 8px 14px; border-radius: var(--r-lg); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); transition: box-shadow var(--wl-quick) var(--wl-ease); }
.wt-sc-ask:focus-within, .wt-sc-ask.is-typed { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 55%, var(--wl-line)); }
.wt-sc-ask .wt-orbis-blob { --size: 22px; }
.wt-surface .wt-sc-ask textarea { display: block; width: 100%; min-height: 22px; max-height: 140px; margin: 0; padding: 5px 0; border: 0; border-radius: 0; background: none; box-shadow: none; color: var(--wl-text); font: inherit; font-size: 13.5px; line-height: 1.5; resize: none; }
.wt-surface .wt-sc-ask textarea:focus { outline: none; box-shadow: none; }
.wt-surface .wt-sc-ask textarea::placeholder { color: var(--wl-text-3); }
.wt-surface .wt-sc-make { display: inline-flex; align-items: center; gap: 7px; height: 32px; margin: 0; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: none; color: var(--wl-text-3); font-size: 13px; font-weight: 600; white-space: nowrap; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-sc-ask.is-typed .wt-sc-make:not(:disabled) { background: var(--wl-accent); color: var(--wl-on-accent); }
.wt-surface .wt-sc-make:disabled { cursor: default; }
.wt-sc-make .wt-glyph, .wt-sc-make svg { width: 14px; height: 14px; }
.wt-sc-ideas { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.wt-sc-ideas > span { margin-right: 4px; color: var(--wl-text-3); font-size: 12px; }
.wt-surface .wt-sc-idea { display: inline-flex; align-items: center; height: 28px; margin: 0; padding: 0 11px; border: 0; border-radius: var(--r-pill); background: none; box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); font-size: 12.5px; cursor: pointer; }
.wt-surface .wt-sc-idea:hover { background: var(--wl-raised); color: var(--wl-text); }
/* Ready-made (D-155): systems that fit the type, under its scripts. Each opens in place like a script:
   what it uses, the one thing it asks, what it adds (marked new) and what you get. */
.wt-rm { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.wt-rm-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; color: var(--wl-text-3); font-size: 12.5px; }
.wt-rm-head b { color: var(--wl-text-2); font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.wt-rm-add { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.wt-rm-add .wt-glyph, .wt-rm-add svg { width: 14px; height: 14px; color: var(--wl-text-2); }
.wt-rm-tag { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: inset 0 0 0 1px var(--wl-line-strong); color: var(--wl-text-2); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.wt-rm-tag .wt-glyph, .wt-rm-tag svg { width: 14px; height: 14px; }
.wt-rm-tag.is-small { height: 20px; margin-left: 8px; padding: 0 8px; gap: 5px; font-size: 11px; vertical-align: 1px; }
.wt-rm-tag.is-small .wt-glyph, .wt-rm-tag.is-small svg { width: 12px; height: 12px; }
.wt-sc-chip i { color: var(--wl-text-3); font-style: normal; }
.wt-sc-chip.is-new { background: color-mix(in srgb, var(--wl-selection) 10%, var(--wl-raised)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 50%, transparent); }
.wt-rm-ask { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.wt-rm-ask select { min-width: 160px; max-width: 100%; }
.wt-rm-note { color: var(--wl-text-3); font-size: 12.5px; }
.wt-rm-gets { display: flex; flex-direction: column; gap: 3px; margin: 0; padding-left: 16px; color: var(--wl-text-2); }
.wt-rm-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 12px; border-top: 1px solid var(--wl-line); }
.wt-rm-acts .wt-rm-note { flex-basis: 100%; }
.wt-surface .wt-rm-cta { display: inline-flex; align-items: center; gap: 7px; height: 32px; margin: 0; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: var(--wl-accent); box-shadow: none; color: var(--wl-on-accent); font-size: 13px; font-weight: 600; white-space: nowrap; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-rm-cta:hover { background: color-mix(in srgb, var(--wl-accent) 86%, var(--wl-bg)); }
.wt-rm-cta .wt-glyph, .wt-rm-cta svg { width: 14px; height: 14px; }
.wt-rm-foot { margin: 2px 0 0; color: var(--wl-text-3); font-size: 12.5px; line-height: 1.5; }
.wt-rm-foot b { color: var(--wl-text-2); font-weight: 600; }
.wt-sc-try { padding: 10px 12px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 40%, var(--wl-line)); color: var(--wl-text-2); font-size: 12.5px; line-height: 1.5; animation: wt-sc-open .18s ease-out; }
.wt-sc-try[hidden] { display: none; }
.wt-sc-try.wt-ws-page-try { margin: 14px auto 0; }
.wt-sc-try-head { display: flex; align-items: center; gap: 8px; }
.wt-sc-try-head > .wt-glyph, .wt-sc-try-head > svg { width: 14px; height: 14px; color: var(--wl-selection); }
.wt-sc-try-head b { color: var(--wl-text); font-size: 13px; font-weight: 600; }
.wt-surface .wt-sc-try-head .wt-sc-btn { margin-left: auto; height: 26px; padding: 0 10px; font-size: 12px; }
.wt-sc-try-sub { margin: 1px 0 6px 22px; color: var(--wl-text-3); font-size: 12px; }
.wt-sc-try-error { margin: 0 0 0 22px; color: var(--wl-danger); font-size: 12.5px; overflow-wrap: anywhere; }
.wt-sc-try ul { display: flex; flex-direction: column; gap: 3px; margin: 0; padding: 0 0 0 22px; list-style: none; }
.wt-sc-try q { quotes: none; color: var(--wl-text); font-family: var(--wl-font-reading); font-size: 13.5px; }
@container wt-ws (max-width: 560px) {
  .wt-surface .wt-sc-head { grid-template-columns: 34px minmax(0, 1fr) 16px; }
  .wt-sc-start { grid-column: 2; grid-row: 2; justify-self: start; }
  .wt-sc-chev { grid-column: 3; grid-row: 1; }
  .wt-sc-detail { padding-left: 12px; }
  .wt-sc-line { grid-template-columns: 1fr; gap: 4px; }
  .wt-sc-how { grid-template-columns: 1fr; gap: 6px; }
  .wt-sc-ask { grid-template-columns: 22px minmax(0, 1fr); }
  .wt-sc-ask .wt-sc-make { grid-column: 2; justify-self: end; }
  .wt-sc-head > :is(.wt-rm-add, .wt-rm-tag) { grid-column: 2; grid-row: 2; justify-self: start; }
}
.wt-ws-chip-words { display: flex; flex-direction: column; flex: 1; min-width: 0; text-align: left; line-height: 1.25; }
.wt-ws-chip-words small { color: var(--wl-text-3); font-size: 11.5px; font-weight: 400; }
/* On a phone, settings one under another. */
@container wt-ws (max-width: 560px) {
  .wt-ws-play-scroll { padding: 22px 14px 80px; }
  .wt-play-roles { grid-template-columns: minmax(0, 1fr); }
  .wt-play-row { flex-wrap: wrap; gap: 8px; }
  .wt-play-row select { width: 100%; }
  .wt-play-row .wt-play-link { margin-left: auto; }
  .wt-play-set { flex-direction: column; align-items: stretch; gap: 10px; }
  .wt-play-set > .wt-ws-segment { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
  .wt-play-set > select { align-self: flex-start; }
  .wt-ws .wt-play-sec-head { flex-wrap: wrap; row-gap: 6px; }
}

/* On a wide window the left column can be put away from the same button, to give the page room. */
@container wt-ws (min-width: 1100px) {
  .wt-ws.is-design.is-side-hidden .wt-ws-body { grid-template-columns: minmax(0, 1fr) 332px; }
  .wt-ws.is-side-hidden .wt-ws-side { display: none; }
}
/* Narrower windows: the left column slides over the page from its own button in the page's bar */
@container wt-ws (max-width: 1099px) {
  .wt-ws.is-design .wt-ws-body { grid-template-columns: minmax(0, 1fr) 312px; --wt-ws-side-drawer: 1; }
  .wt-ws-side { position: absolute; top: 0; bottom: 0; left: 0; z-index: 21; width: min(292px, 88%); box-shadow: var(--wl-elev-pop); transform: translateX(-104%); visibility: hidden; transition: transform var(--wl-short) var(--wl-ease), visibility 0s var(--wl-short); }
  .wt-ws.is-side-open .wt-ws-side { transform: none; visibility: visible; transition: transform var(--wl-short) var(--wl-ease); }
  .wt-surface .wt-ws-side .wt-ws-side-close { display: grid; position: absolute; top: 14px; right: 10px; }
  .wt-ws-side-tabs { margin-right: 48px; }
}
@container wt-ws (max-width: 799px) {
  .wt-ws.is-design .wt-ws-body { grid-template-columns: minmax(0, 1fr); }
  .wt-ws.is-design .wt-ws-scroll { padding: 70px 12px 40px; }
  .wt-ws-pbar-dim { display: none; }
  /* Boris docked keeps the panel beside the page only while the page keeps 480px (boris-panel.css, D-369). */
}
@container wt-ws (max-width: 599px) {
  .wt-ws-side { width: 100%; top: auto; height: min(78%, 660px); border-right: 0; border-top: 1px solid var(--wl-line); border-radius: var(--r-xl) var(--r-xl) 0 0; box-shadow: var(--wl-elev-pop); transform: translateY(104%); }
  .wt-ws-pbar { top: 10px; }
  .wt-ws-pbar-widths, .wt-ws-pbar-sep:has(+ .wt-ws-pbar-widths) { display: none; }
  .wt-ws-pbar-who > span:not(.wt-glyph):not(.wt-portrait) { max-width: 80px; overflow: hidden; text-overflow: ellipsis; }
}
@media (prefers-reduced-motion: reduce) { .wt-ws-side { transition: none !important; } }

/* ---- The right column as cards (D-113, board 5's 1-B with its two sides) ---- */
.wt-ws.is-design .wt-ws-panel { background: var(--wl-bg); }
.wt-ws.is-design .wt-ws-panel-body { padding: 4px 16px 92px; }
.wt-ws-inspect-head { display: flex; align-items: flex-start; gap: 12px; padding: 16px 0 10px; }
.wt-ws-inspect-icon { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: var(--r-md); background: var(--wl-raised); color: var(--wl-text-2); }
.wt-ws-inspect-icon .wt-glyph { width: 17px; height: 17px; }
.wt-ws-inspect-titles { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
/* What is selected has one title look (D-270), the same as a field's name typed over in place, so the
   title does not change font from one part to the next. */
.wt-ws-inspect-titles h3 { margin: 3px 0 2px; font: 600 17px/1.25 var(--wl-font-ui); letter-spacing: 0; color: var(--wl-text); overflow-wrap: anywhere; }
.wt-ws input.wt-ws-inspect-name { width: calc(100% + 8px); height: 30px; margin: -2px -4px 0; padding: 0 4px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font: 600 17px/1.25 var(--wl-font-ui); letter-spacing: 0; text-overflow: ellipsis; }
.wt-ws input.wt-ws-inspect-name:hover { background: var(--wl-raised); }
.wt-ws input.wt-ws-inspect-name:focus { background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-selection); outline: none; }
.wt-ws-inspect-titles small { display: flex; align-items: center; gap: 6px; min-width: 0; color: var(--wl-text-2); font-size: 12.5px; white-space: nowrap; }
.wt-ws-inspect-sep { color: var(--wl-text-3); }
.wt-ws-inspect-reach::before, .wt-ws-reach-now strong::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: var(--wt-reach); vertical-align: 1px; }
.wt-ws .wt-ws-inspect-more, .wt-ws .wt-ws-inspect-close { flex: none; width: 30px; height: 30px; margin: 3px 0 0; border-radius: var(--r-pill); }
.wt-ws .wt-ws-inspect-more { margin-right: -6px; }
/* Tabs in the editor are one rail (D-270), here, in Add and On the page, and in Code: words on a thin
   line, the open one brighter with a short bar under it. No icons, no pills. */
.wt-ws-inspect-tabs, .wt-ws-side-tabs { display: flex; gap: 4px; padding: 0; border: 0; border-bottom: 1px solid var(--wl-line); border-radius: 0; background: none; }
.wt-ws-inspect-tabs { margin: 6px 0 4px; }
.wt-surface :is(.wt-ws-inspect-tab, .wt-ws-side-tab, .wt-ws-code-tab) { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; height: 34px; margin: 0 0 -1px; padding: 0 10px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 12.5px; font-weight: 500; transition: color var(--wl-quick) var(--wl-ease), border-color var(--wl-quick) var(--wl-ease); }
.wt-surface :is(.wt-ws-inspect-tab, .wt-ws-side-tab, .wt-ws-code-tab):hover { color: var(--wl-text); background: transparent; }
.wt-surface :is(.wt-ws-inspect-tab, .wt-ws-side-tab, .wt-ws-code-tab)[aria-selected="true"] { color: var(--wl-text); background: transparent; box-shadow: none; border-bottom-color: var(--wl-selection); }
:is(.wt-ws-inspect-tab, .wt-ws-side-tab) .wt-glyph { display: none; }

/* A card: an icon, a title and a line, then its settings */
.wt-ws-card { margin-top: 8px; padding: 10px 12px 12px; border-radius: var(--r-lg); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-ws-card-head { display: flex; align-items: center; gap: 8px; min-height: 22px; margin-bottom: 4px; }
.wt-ws-card-head .wt-glyph { width: 14px; height: 14px; color: var(--wl-text-3); }
.wt-ws-card-title { font-size: var(--t-title-card); font-weight: 600; color: var(--wl-text); }
.wt-ws-card-head small { margin-left: auto; color: var(--wl-text-3); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wt-ws-card .wt-prop { border-bottom: 0; }
.wt-ws-card .wt-prop + .wt-prop, .wt-ws-card .wt-prop-switch + .wt-prop, .wt-ws-card .wt-prop + .wt-prop-switch, .wt-ws-card .wt-prop-switch + .wt-prop-switch { border-top: 1px solid var(--wl-line); }
.wt-ws-card .wt-prop-switch { min-height: 34px; padding: 6px 0; }
.wt-ws-card .wt-prop-switch > .wt-prop-name { color: var(--wl-text-2); font-size: 13px; font-weight: 400; }
.wt-ws-card .wt-prop-switch > .wt-prop-name small { color: var(--wl-text-3); font-size: 11.5px; }
.wt-ws-card > .wt-ws-control-label { display: block; margin: 10px 0 6px; color: var(--wl-text-2); font-size: 12px; font-weight: 400; }
.wt-ws-card-head + .wt-ws-control-label { margin-top: 6px; }
.wt-ws-card > .wt-ws-hint, .wt-ws-card > small.wt-ws-hint { display: block; margin: 8px 0 0; color: var(--wl-text-3); font-size: 11.5px; line-height: 1.5; }
.wt-ws-card .wt-ws-segment { padding: 2px; gap: 2px; border: 0; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-surface .wt-ws-card .wt-ws-segment button { height: 26px; border-radius: var(--r-sm); color: var(--wl-text-2); font-size: 12px; }
.wt-surface .wt-ws-card .wt-ws-segment button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); box-shadow: inset 0 0 0 1px var(--wl-line-strong); font-weight: 500; }
/* Beside it (D-143): nine squares, each the part and the words beside it in that spot. */
.wt-ws-sits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; padding: 3px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-surface .wt-ws-sits button { display: grid; place-items: center; height: 42px; padding: 0; border: 0; border-radius: var(--r-sm); background: transparent; color: var(--wl-text-3); cursor: pointer; }
.wt-surface .wt-ws-sits button:hover { color: var(--wl-text-2); background: color-mix(in srgb, var(--wl-text) 5%, transparent); }
.wt-surface .wt-ws-sits button[aria-pressed="true"] { background: var(--wl-raised); color: var(--wl-text); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-surface .wt-ws-sits button:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 1px; }
.wt-ws-sits svg { width: 56px; height: 36px; display: block; }
/* A row of choices too long for the card (Shape's five) wraps onto a second line. */
.wt-ws-segment.is-many { flex-wrap: wrap; }
.wt-surface .wt-ws-segment.is-many button { flex: 1 1 30%; }

/* Who knows it: the choice in words, then seven steps */
.wt-ws-reach-now { margin: 2px 0 0; }
.wt-ws-reach-now strong { display: block; font-size: 14px; font-weight: 600; color: var(--wl-text); }
.wt-ws-reach-now span { display: block; margin-top: 1px; color: var(--wl-text-2); font-size: 12.5px; }
.wt-ws-reach-scale { display: flex; gap: 4px; margin: 6px 0 2px; }
.wt-surface .wt-ws-reach-step { position: relative; flex: 1; min-width: 0; height: 20px; padding: 0; border-radius: var(--r-xs); background: transparent; box-shadow: none; }
.wt-ws-reach-step::before { content: ""; position: absolute; left: 0; right: 0; top: 6px; height: 8px; border-radius: var(--r-xs); background: color-mix(in srgb, var(--wt-reach) 24%, var(--wl-raised)); transition: background-color var(--wl-quick) var(--wl-ease); }
.wt-ws-reach-step:hover::before { background: color-mix(in srgb, var(--wt-reach) 55%, var(--wl-raised)); }
.wt-ws-reach-step[aria-checked="true"]::before { background: var(--wt-reach); box-shadow: 0 0 0 2px var(--wl-surface), 0 0 0 3.5px var(--wt-reach); }
.wt-ws-reach-step:focus-visible { outline: none; }
.wt-ws-reach-step:focus-visible::before { box-shadow: 0 0 0 2px var(--wl-surface), 0 0 0 3.5px var(--wl-selection); }
.wt-ws-card .wt-ws-reach-scale + .wt-prop-switch { margin-top: 8px; border-top: 1px solid var(--wl-line); }

/* A number (D-270): its name on the left, the number in a small box with its unit on the right, as
   every row in a card has its value on the right. Drag the name sideways to change it. */
.wt-ws-num { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 40px; padding: 6px 0; }
.wt-ws-num-name { flex: 1; min-width: 0; color: var(--wl-text-2); font-size: 13px; cursor: ew-resize; user-select: none; touch-action: none; transition: color var(--wl-quick) var(--wl-ease); }
.wt-ws-num:hover .wt-ws-num-name, .wt-ws-num.is-scrubbing .wt-ws-num-name { color: var(--wl-text); }
.wt-ws-num.is-scrubbing, .wt-ws-num.is-scrubbing * { cursor: ew-resize !important; }
.wt-ws-num-box { display: inline-flex; align-items: center; gap: 4px; flex: none; width: 78px; height: 28px; padding: 0 9px 0 6px; border-radius: var(--r-sm); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); cursor: text; transition: box-shadow var(--wl-quick) var(--wl-ease); }
.wt-ws-num-box:hover { box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-ws-num-box:focus-within, .wt-ws-num.is-scrubbing .wt-ws-num-box { box-shadow: inset 0 0 0 1px var(--wl-selection); }
.wt-ws .wt-ws-num-box input:not(.wt-switch):not([type="range"]):not([type="color"]) { flex: 1; width: 100%; min-width: 0; height: 26px; min-height: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; color: var(--wl-text); font: 500 13px var(--wl-font-ui); font-variant-numeric: tabular-nums; text-align: right; appearance: textfield; -moz-appearance: textfield; }
.wt-ws .wt-ws-num-box input:focus { outline: none; box-shadow: none; }
.wt-ws-num-box input::-webkit-inner-spin-button, .wt-ws-num-box input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.wt-ws-num-box input::placeholder { color: var(--wl-text-3); font-weight: 400; }
.wt-ws-num-box small { color: var(--wl-text-3); font-size: 11.5px; }
.wt-ws-card .wt-ws-num + .wt-ws-num, .wt-ws-card .wt-ws-num + :is(.wt-prop, .wt-prop-switch, .wt-ws-colour-row), .wt-ws-card :is(.wt-prop, .wt-prop-switch, .wt-ws-colour-row) + .wt-ws-num { border-top: 1px solid var(--wl-line); }
.wt-ws-card .wt-ws-segment + .wt-ws-num, .wt-ws-card .wt-ws-hint + .wt-ws-num { margin-top: 4px; }
.wt-ws-focus-head { display: flex !important; justify-content: space-between; }
.wt-ws-focus-name { color: var(--wl-text); font-weight: 500; }
/* The whole picture at its own shape, so a click lands on that point of it (cropping it would move the point) */
.wt-ws-card .wt-focus { width: fit-content; max-width: 100%; margin-inline: auto; }
.wt-ws-card .wt-focus img { width: auto; max-width: 100%; max-height: 220px; }
.wt-ws-card .wt-focus.is-empty { width: 100%; }
.wt-ws-card .wt-ws-focus-actions { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.wt-ws-card .wt-ws-focus-actions small { color: var(--wl-text-3); font-size: 11.5px; line-height: 1.45; }
.wt-ws-card .wt-ws-focus-actions button { flex: none; height: 28px; padding: 0 10px; font-size: 12px; }

/* Actions at the bottom: pills, the remove one quiet */
.wt-ws.is-design .wt-ws-inspect-actions { gap: 6px; margin-top: 16px; }
.wt-surface .wt-ws.is-design .wt-ws-inspect-actions button, .wt-ws.is-design .wt-surface .wt-ws-inspect-actions button { height: 30px; padding: 0 12px; border-radius: var(--r-pill); }
.wt-ws.is-design .wt-ws-panel .wt-ws-callout { border-radius: var(--r-md); }
.wt-ws-mini:not(:has(> .wt-glyph)) { grid-template-columns: 1fr; }
.wt-surface .wt-ws-card .wt-ws-focus-actions button { border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: none; color: var(--wl-text); }

/* A section's colour behind it: the name, then the swatch with its name (D-111) */
.wt-ws-colour-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; }
.wt-ws-card .wt-ws-colour-row > .wt-ws-control-label { margin: 0; }
/* In a card it is a row like the others (D-270): the name in the rows' size, the swatch on the right. */
.wt-ws-card .wt-ws-colour-row { min-height: 40px; margin-top: 0; padding: 6px 0; }
.wt-ws-card .wt-ws-colour-row > .wt-ws-control-label { color: var(--wl-text-2); font-size: 13px; }
.wt-ws-card .wt-ws-colour-row + :is(.wt-prop, .wt-prop-switch) { border-top: 1px solid var(--wl-line); }
.wt-surface .wt-ws-colour-row .wt-ws-option-colour { display: inline-flex; align-items: center; gap: 7px; width: auto; height: 28px; padding: 0 10px; border-radius: var(--r-pill); color: var(--wl-text); font-size: 12px; }

/* A part's fill (D-117): three small pictures, none, a colour and an image */
.wt-ws-fills { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 2px 0 6px; }
.wt-surface .wt-ws-fill { display: flex; flex-direction: column; align-items: stretch; gap: 6px; height: auto; padding: 6px 6px 7px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); font-size: 12px; text-align: center; }
.wt-surface .wt-ws-fill:hover { box-shadow: inset 0 0 0 1px var(--wl-line-strong); color: var(--wl-text); }
.wt-surface .wt-ws-fill[aria-pressed="true"] { background: var(--wl-raised); box-shadow: inset 0 0 0 1.5px var(--wl-selection); color: var(--wl-text); }
.wt-ws-fill-swatch { display: block; height: 30px; border-radius: var(--r-sm); background: var(--wl-bg); }
.wt-ws-fill-swatch.is-none { box-shadow: inset 0 0 0 1px var(--wl-line); background: repeating-linear-gradient(135deg, transparent 0 5px, color-mix(in srgb, var(--wl-line) 70%, transparent) 5px 6px), var(--wl-bg); }
.wt-ws-fill-swatch.is-colour { background: color-mix(in srgb, var(--wl-fill-c, var(--wl-text-3)) 30%, var(--wl-raised)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-fill-c, var(--wl-text-3)) 45%, var(--wl-line)); }
.wt-ws-fill-swatch.is-image { background-color: var(--wl-raised); background-image: linear-gradient(160deg, color-mix(in srgb, var(--wl-accent) 55%, transparent), transparent 70%); background-size: cover; background-position: center; box-shadow: inset 0 0 0 1px var(--wl-line); }
/* Finished pieces (D-264): Stat tiles' style drawn small, a field to show with its settings beside it,
   and a row for each tile (its name, its field, more). */
.wt-ws-fills.is-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.wt-ws-fill-swatch.is-tiles, .wt-ws-fill-swatch.is-strip { display: flex; gap: 3px; padding: 6px; box-sizing: border-box; box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-ws-fill-swatch.is-tiles i { flex: 1; border-radius: 3px; background: var(--wl-line-strong); }
.wt-ws-fill-swatch.is-strip { gap: 0; align-items: center; }
.wt-ws-fill-swatch.is-strip i { flex: 1; height: 60%; border-left: 1.5px solid var(--wl-text-3); }
.wt-ws-fill-swatch.is-strip i:first-child { border-left: 0; }
/* One of many (D-271), the same in every panel: the choice in a box like the boxes you type in, with a
   chevron, opening a short menu. Fixed once saved, it has a lock instead and is quieter. */
.wt-ws-pick-line { display: flex; align-items: center; gap: 6px; }
.wt-surface .wt-ws-pick-box { display: flex; align-items: center; justify-content: flex-start; gap: 8px; flex: 1; min-width: 0; height: 34px; padding: 0 10px 0 9px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-inset); box-shadow: none; color: var(--wl-text); font-size: 12.5px; font-weight: 400; text-align: left; cursor: pointer; transition: border-color var(--wl-quick) var(--wl-ease); }
.wt-surface .wt-ws-pick-box:hover { border-color: var(--wl-line-strong); background: var(--wl-inset); }
.wt-surface .wt-ws-pick-box:focus-visible { outline: 2px solid var(--wl-selection); outline-offset: 2px; }
.wt-ws-pick-box > .wt-glyph { flex: none; width: 14px; height: 14px; color: var(--wl-text-3); }
.wt-ws-pick-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wt-surface .wt-ws-pick-box.is-fixed { color: var(--wl-text-2); cursor: default; }
.wt-surface .wt-ws-pick-box.is-fixed:hover { border-color: var(--wl-line); }
.wt-ws-tile-row .wt-ws-pick-box { padding: 0 8px; font-size: 12px; }
/* Numbers typed in a card have no spin arrows, as the number rows have none. */
.wt-ws-card input[type="number"] { appearance: textfield; -moz-appearance: textfield; }
.wt-ws-card input[type="number"]::-webkit-inner-spin-button, .wt-ws-card input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
/* A name above its control (D-271): one size and colour for every label in a card, the same space above. */
.wt-ws-card .wt-ws-control { margin-top: 10px; gap: 6px; }
.wt-ws-card-head + .wt-ws-control, .wt-ws-card-head + .wt-ws-pair > .wt-ws-control { margin-top: 6px; }
.wt-ws-card .wt-ws-control-label + .wt-ws-pair > .wt-ws-control { margin-top: 0; }
.wt-ws-card .wt-ws-control > span:first-child { color: var(--wl-text-2); font-size: 12px; font-weight: 400; }
/* A box you type in shows no hover label: its name is above it or in it (an option's, a bond's). */
.wt-ws-panel :is(input:not([type="checkbox"]):not([type="color"]), textarea) { --no-tooltip: true; }
.wt-ws-card .wt-ws-control textarea:not(.wt-code) { min-height: 58px; resize: vertical; line-height: 1.5; }
.wt-ws-card :is(.wt-ws-control, .wt-ws-pair, .wt-ws-segment, .wt-ws-hint, .wt-ws-choice-chips) + :is(.wt-ws-num, .wt-prop-switch, .wt-ws-colour-row) { margin-top: 4px; }
/* A fixed choice shows its answer; the others are faded. */
.wt-surface .wt-ws-card .wt-ws-segment.is-fixed button { cursor: default; opacity: 1; }
.wt-surface .wt-ws-card .wt-ws-segment.is-fixed button:not([aria-pressed="true"]) { opacity: .4; }
/* A formula's card: the formula, what it gives now, what can go in it. */
.wt-ws-card > textarea.wt-ws-formula-input { display: block; width: 100%; min-height: 64px; margin-top: 8px; resize: vertical; font: 11.5px/1.55 var(--wl-font-mono); }
.wt-ws-card > .wt-ws-formula-result { margin-top: 6px; }
/* A list's Add under it (Options, Bonds, a piece's numbers and rows). */
.wt-ws-card > .wt-ws-options + .wt-ws-option-add { margin-top: 6px; }
.wt-ws-pick-line .wt-icon-button, .wt-ws-piece-field-gap { flex: none; width: 34px; height: 34px; border-radius: var(--r-sm); }
.wt-ws-tile-rows { display: flex; flex-direction: column; gap: 6px; margin: 4px 0 6px; }
.wt-ws-tile-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 26px; gap: 5px; align-items: center; padding-bottom: 6px; border-bottom: 1px solid var(--wl-line); }
.wt-ws-tile-row input, .wt-ws-tile-row select { min-width: 0; width: 100%; height: 28px; font-size: 12px; }
.wt-ws-tile-row input { padding: 2px 6px; }
.wt-ws-tile-row .wt-icon-button { width: 26px; height: 26px; }
/* A test picture for a picture part: shown in this editor only */
.wt-ws-test-picture { display: flex; align-items: center; gap: 10px; margin: 10px 0 2px; padding: 8px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-ws-test-thumb { display: grid; place-items: center; flex: none; width: 36px; height: 36px; overflow: hidden; border-radius: var(--r-md); background: var(--wl-raised); box-shadow: 0 0 0 1px var(--wl-line-strong); color: var(--wl-text-3); }
.wt-ws-test-thumb img { width: 100%; height: 100%; object-fit: cover; }
.wt-ws-test-thumb.is-empty .wt-glyph { width: 16px; height: 16px; }
.wt-ws-test-words { display: flex; flex-direction: column; gap: 1px; flex: 1; min-width: 0; }
.wt-ws-test-words strong { overflow: hidden; color: var(--wl-text); font-size: 12.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.wt-ws-test-words small { color: var(--wl-text-3); font-size: 11px; line-height: 1.35; }
.wt-surface .wt-ws-test-pick { flex: none; height: 28px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12px; }
.wt-ws-test-picture .wt-icon-button { flex: none; width: 28px; height: 28px; border-radius: var(--r-pill); }
.wt-ws-menu-item > .wt-ws-menu-picture { flex: none; width: 28px; height: 28px; object-fit: cover; border-radius: var(--r-sm); box-shadow: 0 0 0 1px var(--wl-line); }
/* The picture comes before the words (canvas-editor.mjs menu), so a sibling says the item has one; not :has() (see the pick bar). */
.wt-ws-menu-item > .wt-ws-menu-picture ~ .wt-ws-menu-text > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Boris as a sheet along the bottom (D-148, on every page since D-369): when the window is too narrow for the page and
   Boris side by side (a phone, a tablet held upright), boris-panel.mjs marks him .is-sheet. He rises over the bottom half,
   from the rail's edge to the window's, and the work in the row moves up into the half above at its full width, so
   nothing of it hides under him. His handle makes him full height and back. */
body { --wt-orbis-sheet: 52vh; }
body button.wt-orbis-grab { display: none; }
.wt-orbis-panel.is-sheet:not(.is-embedded) { position: fixed; inset: auto 0 0 var(--wt-orbis-sheet-left, 0px) !important; z-index: 40; flex: none; width: auto !important; height: var(--wt-orbis-sheet) !important; min-width: 0; min-height: 0; max-width: none; max-height: none; resize: none; border: 0; border-radius: var(--r-xl) var(--r-xl) 0 0; box-shadow: 0 0 0 1px var(--wl-line), var(--wl-elev-pop); }
.wt-orbis-panel.is-sheet.is-sheet-full:not(.is-embedded) { inset: var(--wt-orbis-top, 60px) 0 0 var(--wt-orbis-sheet-left, 0px) !important; height: auto !important; border-radius: 0; }
.wt-orbis-panel.is-sheet:not(.is-embedded) .wt-orbis-inner { width: 100%; border-radius: inherit; animation: wl-rise var(--wl-long) var(--wl-ease-out); }
.wt-orbis-panel.is-sheet.is-closing:not(.is-embedded) .wt-orbis-inner { translate: 0 8px; }
.wt-orbis-panel.is-sheet:not(.is-embedded) :is(.wt-orbis-edge, .wt-orbis-grip) { display: none; }
.wt-orbis-panel.is-sheet:not(.is-embedded) .wt-orbis-bar { position: relative; padding-top: 14px; cursor: default; }
body .wt-orbis-panel.is-sheet:not(.is-embedded) button.wt-orbis-grab { display: block; position: absolute; top: 0; left: 50%; width: 64px; height: 16px; margin-left: -32px; padding: 0; border: 0; border-radius: var(--r-md); background: transparent; box-shadow: none; cursor: pointer; }
body .wt-orbis-panel.is-sheet button.wt-orbis-grab::before { content: ""; position: absolute; top: 6px; left: 13px; width: 38px; height: 4px; border-radius: var(--r-md); background: var(--wl-line-strong); }
body .wt-orbis-panel.is-sheet button.wt-orbis-grab:hover::before { background: var(--wl-text-3); }
/* The work above him: everything in the row except the rail, drawer, and Boris stops at the sheet's top edge. */
body.wt-orbis-sheet .wl-workspace-body > :not(.wl-rail):not(.wl-drawer-shell):not(.wl-drawer-backdrop):not(.wt-orbis-panel):not(.wt-orbis-orb) { margin-bottom: var(--wt-orbis-sheet); }
@media (max-width: 768px) {
  body { --wt-orbis-top: 54px; }
  .wt-orbis-panel.is-sheet:not(.is-embedded) { inset: auto 0 0 0 !important; padding-bottom: env(safe-area-inset-bottom, 0px); }
  .wt-orbis-panel.is-sheet.is-sheet-full:not(.is-embedded) { inset: 54px 0 0 0 !important; }
  .wt-ws-menu { max-width: calc(100vw - 20px); }
  .wt-pagebar { flex-wrap: wrap; gap: 6px 10px; padding: 8px 12px; }
  .wt-entry-page { padding-inline: 12px; }
  .wt-library { padding: 16px 14px; }
  .wt-type-row { flex-wrap: wrap; gap: 10px; padding: 14px 0; }
}
@media (prefers-reduced-motion: reduce) { .wt-orbis-panel.is-sheet:not(.is-embedded) .wt-orbis-inner { animation: wl-fade 150ms linear; } }
/* What Boris or another AI changed, in Code (D-148): a strip that counts the changes and steps through them, the lines marked. */
.wt-ws-code-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; flex-shrink: 0; padding: 6px 8px 6px 12px; border-radius: var(--r-md); background: color-mix(in srgb, var(--wl-accent) 7%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-accent) 22%, transparent); color: var(--wl-text-2); font-size: var(--t-ui); animation: wt-orbis-fade var(--wl-short) var(--wl-ease-out); }
.wt-ws-code-strip[hidden], .wt-ws-code-only[hidden], .wt-ws-code-surface[hidden] { display: none; }
.wt-ws-code-strip > .wt-glyph { flex-shrink: 0; color: var(--wl-text-2); }
.wt-ws-code-strip .wt-glyph svg { width: 15px; height: 15px; }
.wt-ws-code-strip-words { flex: 1 1 160px; min-width: 0; }
.wt-ws-code-strip-words b { color: var(--wl-text); font-weight: 600; }
body .wt-ws button.wt-ws-code-strip-button { display: inline-flex; align-items: center; gap: 5px; height: 26px; min-width: 26px; padding: 0 8px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: var(--t-help); }
body .wt-ws button.wt-ws-code-strip-button:hover { color: var(--wl-text); background: color-mix(in srgb, var(--wl-text) 8%, transparent); }
body .wt-ws button.wt-ws-code-strip-button.is-on { color: var(--wl-text); background: color-mix(in srgb, var(--wl-accent) 16%, transparent); }
.wt-ws-code-surface { position: relative; }
.wt-ws-code-band-layer { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 1; }
.wt-ws-code-bands { position: absolute; inset: 0 0 auto 0; }
.wt-ws-code-band { position: absolute; left: 0; right: 0; background: color-mix(in srgb, var(--wl-accent) 7%, transparent); }
.wt-ws .wt-ws-code-lines > span.is-changed { color: var(--wl-text); box-shadow: inset -3px 0 0 color-mix(in srgb, var(--wl-accent) 70%, transparent); }
.wt-ws .wt-ws-code-lines > span { display: inline-block; width: calc(100% + 8px); margin-right: -8px; padding-right: 8px; }
.wt-ws .wt-ws-code-lines > span.is-cut { box-shadow: inset -3px 2px 0 -1px color-mix(in srgb, var(--wl-danger) 70%, transparent); }
.wt-ws-code-only { display: flex; flex-direction: column; gap: 8px; flex: 1 0 260px; min-height: 260px; overflow: auto; }
/* A type's Code as a code editor, as a mechanic's is (D-339): the files' tabs and the tools in one bar, the code edge
   to edge in colour with the caret's line and brackets marked (code-box.mjs), what needs fixing under it, where the
   caret is in a slim foot, and the help over the editor. Its sizes and gaps are the action code's. */
.wt-ws .wt-ws-code { gap: 0; padding: 0; background: var(--wl-bg); }
.wt-ws-code > .wt-ws-code-bar { flex-wrap: wrap; align-items: center; gap: 4px 12px; min-height: 46px; padding: 0 12px 0 16px; }
.wt-ws-code-bar > .wt-ws-code-tabs { align-self: flex-end; }
.wt-ws-code-bar > .wt-ws-code-tools { margin-inline-start: auto; padding: 6px 0; }
/* Preview (code-view.mjs, syncCodePreview): the card hidden gives the code the whole room; where the two don't fit side
   by side, the card stands in for the code under the same bar, and the tools that write into the code step aside. */
.wt-ws-code-tool.wt-ws-code-preview[aria-pressed="true"] { background: var(--wl-selection-soft); color: var(--wl-text); }
/* A narrow code pane (beside the card on a small window) keeps its tools in one row as icons; each keeps its name for
   screen readers and its tooltip. */
.wt-ws .wt-ws-code { container: wt-code / inline-size; }
@container wt-code (max-width: 560px) {
  .wt-surface .wt-ws-code-tools .wt-ws-code-tool:not(.wt-icon-button) > span:not(.wt-glyph) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .wt-surface .wt-ws-code-tools .wt-ws-code-tool { width: 30px; padding: 0; justify-content: center; }
  .wt-ws-code > .wt-ws-code-bar { gap: 4px 8px; padding: 4px 8px 0 10px; min-height: 42px; }
  .wt-ws .wt-ws-code-surface { min-width: 0; overflow: hidden; }
  .wt-ws .wt-ws-code-surface .wt-ws-code-lines { flex: 0 0 38px; min-width: 38px; box-sizing: border-box; padding: 12px 6px 72px 4px; font: 11.5px/1.7 var(--wl-font-mono); text-align: right; }
  .wt-ws .wt-ws-code-surface .wt-ws-code-lines > span { width: 100%; margin-right: 0; padding-right: 2px; }
  .wt-ws .wt-ws-code-ink,
  .wt-ws .wt-ws-code-well > textarea.wt-ws-code-editor { padding: 12px 12px 72px; font: 12px/1.7 var(--wl-font-mono); -webkit-overflow-scrolling: touch; }
  .wt-ws-code > .wt-ws-code-footer { padding: 7px 12px; font-size: 11.5px; }
}
.wt-ws.is-code.is-preview-hidden .wt-ws-body { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
.wt-ws.is-code.is-preview-hidden .wt-ws-stage { display: none; }
.wt-ws.is-code.is-preview-hidden .wt-ws-code { border-right: 0; border-bottom: 0; }
.wt-ws.is-code.is-code-hidden .wt-ws-body { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
.wt-ws.is-code.is-code-hidden .wt-ws-code > :not(.wt-ws-code-bar, .wt-ws-code-drawer) { display: none; }
.wt-ws.is-code.is-code-hidden .wt-ws-code-tool.is-edit { display: none; }
.wt-ws-code > :is(.wt-ws-code-drawer, .wt-ws-code-strip) { margin: 10px 16px 0; }
.wt-ws-code > .wt-ws-code-only { padding: 12px 16px; }
.wt-ws-code > .wt-ws-code-surface { flex: 1 1 0; min-height: 200px; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.wt-ws .wt-ws-code-surface .wt-ws-code-lines { flex: 0 0 46px; padding: 16px 10px 16px 0; border-right: 1px solid var(--wl-line); background: transparent; font: 13px/1.75 var(--wl-font-mono); }
.wt-ws .wt-ws-code-surface .wt-ws-code-lines > span { width: calc(100% + 10px); margin-right: -10px; padding-right: 10px; }
.wt-ws-code-surface:focus-within .wt-ws-code-lines { color: var(--wl-text-2); }
.wt-ws-code-well { position: relative; display: flex; flex: 1; min-width: 0; min-height: 0; overflow: hidden; }
.wt-ws .wt-ws-code-ink { position: absolute; inset: 0; margin: 0; padding: 16px 18px; overflow: clip; border: 0; border-radius: 0; background: none; color: var(--wl-text); font: 13px/1.75 var(--wl-font-mono); tab-size: 2; white-space: pre; pointer-events: none; }
.wt-ws .wt-ws-code-ink > code { display: block; margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; white-space: inherit; }
.wt-ws .wt-ws-code-well > textarea.wt-ws-code-editor { position: relative; flex: 1; width: 0; height: 100%; padding: 16px 18px; font: 13px/1.75 var(--wl-font-mono); tab-size: 2; color: transparent; -webkit-text-fill-color: transparent; caret-color: var(--wl-accent); }
.wt-ws .wt-ws-code-well > textarea.wt-ws-code-editor::selection { background: color-mix(in srgb, var(--wl-accent) 32%, transparent); }
.wt-ws .wt-ws-code > .wt-ws-code-error { margin: 10px 16px; }
.wt-ws-code > .wt-ws-code-notes { padding: 0 16px 10px; }
.wt-ws-code > .wt-ws-code-error:empty + .wt-ws-code-notes { padding-top: 10px; }
.wt-ws-code > .wt-ws-code-footer { padding: 7px 16px; border-top: 1px solid var(--wl-line); }
/* The help over the editor lists its codes as an action's does; the field kinds and capability keys wrap. */
.wl-me-help .wt-ws-code-kinds { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.wl-me-help .wt-ws-code-kinds code { padding: 0; background: none; color: var(--wl-text-2); font: 11.5px/1.5 var(--wl-font-mono); }
body .wt-ws button.wt-ws-code-place { display: flex; flex-direction: column; align-items: stretch; gap: 0; height: auto; padding: 0; border: 1px solid var(--wl-line); border-radius: var(--r-md); background: var(--wl-bg); box-shadow: none; text-align: left; overflow: hidden; cursor: pointer; }
body .wt-ws button.wt-ws-code-place:hover { border-color: var(--wl-line-strong); }
.wt-ws-code-place-head { padding: 6px 10px; border-bottom: 1px solid var(--wl-line); color: var(--wl-text-2); font-size: var(--t-help); font-weight: 600; }
.wt-ws .wt-ws-code-place-lines { margin: 0; padding: 6px 0; overflow-x: auto; background: transparent; font: 12px/1.8 var(--wl-font-mono); color: var(--wl-text-2); white-space: pre; border-radius: 0; }
.wt-ws-code-place-lines > span { display: block; padding-right: 12px; }
.wt-ws-code-place-lines > span > i { display: inline-block; width: 38px; margin-right: 10px; padding-right: 8px; color: var(--wl-text-3); font-style: normal; text-align: right; user-select: none; }
.wt-ws-code-place-lines > span.is-added { background: color-mix(in srgb, var(--wl-accent) 9%, transparent); color: var(--wl-text); }
.wt-ws-code-place-lines > span.is-removed { background: color-mix(in srgb, var(--wl-danger) 9%, transparent); color: var(--wl-text-3); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--wl-danger) 50%, transparent); }
.wt-ws-code-place-lines > span > i { text-decoration: none; }
@media (prefers-reduced-motion: reduce) { .wt-ws-code-strip { animation: none; } }
/* Another AI's answer waits unsaved (D-148): Keep and Undo all under what it changed. */
.wt-ws-code-ai-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 8px; }
.wt-ws-code-ai-actions button { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; font-size: var(--t-help); }
.wt-ws-code-ai-actions small { flex-basis: 100%; }
.wt-ws-code-ai .wt-ws-segment { margin-top: 8px; }

/* A script's own tab (D-156): the bar, what it works on, the code, and Test (a terminal) under it. */
.wl-se-surface { overflow: hidden; background: var(--wl-bg); }
.wl-se { --wl-se-test: 38%; display: flex; flex-direction: column; flex: 1; min-height: 0; color: var(--wl-text); font-family: var(--wl-font-ui); }
.wl-se button { font-family: inherit; }
.wl-se .wt-glyph { display: inline-flex; flex-shrink: 0; width: 14px; height: 14px; }
.wl-se .wt-glyph svg { width: 14px; height: 14px; }
.wl-se-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-height: 54px; padding: 9px 14px 9px 18px; border-bottom: 1px solid var(--wl-line); }
.wl-se-crumbs { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 13px; }
.wl-se-crumbs b { overflow: hidden; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.wl-se .wl-se-crumb { height: auto; margin: 0; padding: 2px 4px; border: 0; border-radius: var(--r-xs); background: none; box-shadow: none; color: var(--wl-text-3); font-size: 13px; cursor: pointer; }
.wl-se .wl-se-crumb:hover { color: var(--wl-text); }
.wl-se-sep { color: var(--wl-text-3); }
.wl-se-state { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px; border-radius: var(--r-pill); background: var(--wl-surface); color: var(--wl-success); font-size: 11.5px; white-space: nowrap; }
.wl-se-state[data-state="error"] { color: var(--wl-danger); }
.wl-se-state[data-state="busy"] { color: var(--wl-text-3); }
.wl-se-gap { flex: 1; }
.wl-se-ask { color: var(--wl-text-2); font-size: 12.5px; }
.wl-se .wl-se-btn { display: inline-flex; align-items: center; gap: 7px; height: 30px; margin: 0; padding: 0 12px; border: 0; border-radius: var(--r-pill); background: var(--wl-raised); box-shadow: none; color: var(--wl-text); font-size: 12.5px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), opacity var(--wl-quick) var(--wl-ease); }
.wl-se .wl-se-btn.is-quiet { background: transparent; color: var(--wl-text-2); }
.wl-se .wl-se-btn.is-quiet:hover { background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-se-btn.is-cta { background: var(--wl-accent); color: var(--wl-on-accent); font-weight: 600; }
.wl-se .wl-se-btn.is-cta:disabled { opacity: .45; cursor: default; }
.wl-se .wl-se-btn.is-danger { background: color-mix(in srgb, var(--wl-danger) 22%, var(--wl-surface)); color: var(--wl-danger); }
.wl-se .wl-se-icon { display: inline-grid; place-items: center; width: 30px; height: 30px; margin: 0; padding: 0; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); cursor: pointer; }
.wl-se .wl-se-icon:hover, .wl-se .wl-se-icon[aria-expanded="true"] { background: var(--wl-surface); color: var(--wl-text); }
.wl-se-k { margin-right: 2px; color: var(--wl-text-3); font-size: 11.5px; letter-spacing: .02em; }
.wl-se-type.is-file { padding-right: 9px; background: color-mix(in srgb, var(--wl-selection) 12%, var(--wl-raised)); }
.wl-se-type.is-file .wt-glyph, .wl-se-type.is-file svg { width: 12px; height: 12px; color: var(--wl-text-2); }
.wl-se-type { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 4px 0 9px; border-radius: var(--r-pill); background: var(--wl-raised); color: var(--wl-text); }
.wl-se .wl-se-x { display: inline-grid; place-items: center; width: 20px; height: 20px; margin: 0; padding: 0; border: 0; border-radius: 50%; background: transparent; box-shadow: none; color: var(--wl-text-3); cursor: pointer; }
.wl-se .wl-se-x:hover { background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-se-x .wt-glyph, .wl-se .wl-se-x svg { width: 12px; height: 12px; }
.wl-se select.wl-se-add { height: 26px; padding: 0 26px 0 10px; border: 1px dashed var(--wl-line-strong); border-radius: var(--r-pill); background-color: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 12px; }
.wl-se-code { display: flex; flex: 1; min-width: 0; background: var(--wl-bg); }
.wl-se .wl-se-lines { flex: 0 0 46px; margin: 0; padding: 14px 10px 14px 0; overflow: hidden; border: 0; border-right: 1px solid var(--wl-line); border-radius: 0; background: var(--wl-inset); color: var(--wl-text-3); font: 12.5px/1.75 var(--wl-font-mono); text-align: right; user-select: none; }
.wl-se textarea.wl-se-editor { flex: 1; width: 0; min-width: 0; height: 100%; margin: 0; padding: 14px 16px; border: 0; border-radius: 0; outline: none; resize: none; overflow: auto; background: transparent; box-shadow: none; color: var(--wl-text); font: 12.5px/1.75 var(--wl-font-mono); tab-size: 2; white-space: pre; caret-color: var(--wl-accent); }
.wl-se textarea.wl-se-editor:focus { border: 0; box-shadow: none; }
.wl-se-guide { display: grid; gap: 2px; margin: 0; }
.wl-se-guide dt { color: var(--wl-text); font: 11.5px/1.5 var(--wl-font-mono); overflow-wrap: anywhere; }
.wl-se-guide dd { margin: 0 0 6px; color: var(--wl-text-2); font-size: 12px; line-height: 1.5; }
.wl-se-test-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 8px 12px 8px 14px; border-bottom: 1px solid var(--wl-line); }
.wl-se-tabs { display: flex; gap: 2px; }
.wl-se .wl-se-tab { display: inline-flex; align-items: center; gap: 6px; height: 28px; margin: 0; padding: 0 10px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 12.5px; font-weight: 500; cursor: pointer; }
.wl-se .wl-se-tab[aria-selected="true"] { background: var(--wl-raised); color: var(--wl-text); }
.wl-se-count { min-width: 18px; padding: 0 5px; border-radius: var(--r-pill); background: var(--wl-surface); color: var(--wl-text-3); font-family: var(--wl-font-mono); font-size: 11px; line-height: 18px; text-align: center; font-variant-numeric: tabular-nums; }
.wl-se-count[data-has="true"] { background: color-mix(in srgb, var(--wl-danger) 20%, var(--wl-surface)); color: var(--wl-danger); }
/* Try in a game (D-157): the test ground, beside Run. Brass like the test ground's edge; Run stays the one filled button. */
.wl-se-body { flex: 1; min-height: 0; overflow: auto; padding: 10px 14px; font: 12px/1.7 var(--wl-font-mono); }
.wl-se-empty { margin: 0; color: var(--wl-text-3); font: 12.5px/1.6 var(--wl-font-ui); }
.wl-se-line { display: flex; align-items: flex-start; gap: 8px; margin: 0; padding-left: 22px; color: var(--wl-text); line-height: 1.7; }
.wl-se-line > .wt-glyph { margin: 3px 0 0 -22px; }
.wl-se-line > span, .wl-se-line > pre { min-width: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.wl-se-line > pre { margin: 0; padding: 0; border: 0; background: none; color: var(--wl-text); font: inherit; }
.wl-se-line.is-run, .wl-se-line.is-try { margin-top: 10px; color: var(--wl-text-2); }
.wl-se-line.is-run:first-child, .wl-se-line.is-try:first-child { margin-top: 0; }
.wl-se-line.is-run > .wt-glyph, .wl-se-line.is-try > .wt-glyph { color: var(--wl-selection); }
.wl-se-line.is-told { color: var(--wl-text); }
.wl-se-line.is-ask { margin: 8px 0 4px; }
.wl-se-line.is-ask > .wt-glyph { color: var(--wl-selection); }
.wl-se-ask-box { display: grid; gap: 7px; min-width: 0; }
.wl-se-answers { display: flex; flex-wrap: wrap; gap: 6px; }
.wl-se .wl-se-answer { height: 28px; margin: 0; padding: 0 12px; border: 0; border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line-strong); color: var(--wl-text); font: 600 12.5px var(--wl-font-ui); cursor: pointer; }
.wl-se .wl-se-answer:hover:not(:disabled) { box-shadow: inset 0 0 0 1px var(--wl-selection); background: var(--wl-raised); }
.wl-se .wl-se-answer:disabled { opacity: .5; cursor: default; }
.wl-se-line.is-roll, .wl-se-line.is-refused { color: var(--wl-text-2); }
.wl-se-line.is-refused > .wt-glyph { color: var(--wl-warning); }
.wl-se-line.is-error, .wl-se-line.is-error > .wt-glyph { color: var(--wl-danger); }
.wl-se-line.is-ok, .wl-se-line.is-note { color: var(--wl-text-3); }
.wl-se-line.is-ok > .wt-glyph { color: var(--wl-success); }
.wl-se-prompt { display: flex; align-items: center; gap: 8px; padding: 6px 14px 10px; border-top: 1px solid var(--wl-line); }
.wl-se-prompt[hidden] { display: none; }
.wl-se-caret { color: var(--wl-text-3); font: 600 14px var(--wl-font-mono); transition: color var(--wl-quick) var(--wl-ease); }
.wl-se .wl-se-prompt input { flex: 1; min-width: 0; height: 30px; margin: 0; padding: 0; border: 0; outline: none; background: transparent; box-shadow: none; color: var(--wl-text); font: 12px var(--wl-font-mono); }
.wl-se .wl-se-prompt input::placeholder { color: var(--wl-text-3); }
@media (prefers-reduced-motion: reduce) { .wl-se .wl-se-btn { transition: none; } }

/* Steps (D-158): the same script as a list of steps, each a sentence with blanks to click. Steps or Code sits beside the
   state chip. Each kind has a quiet colour (dice brass, checks blue, changes sage, the story parchment, stop red). */
.wl-se-views { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wl-se .wl-se-view { display: inline-flex; align-items: center; gap: 6px; height: 24px; margin: 0; padding: 0 11px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 12px; font-weight: 500; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wl-se .wl-se-view:hover { color: var(--wl-text); }
.wl-se .wl-se-view[aria-selected="true"] { background: var(--wl-raised); color: var(--wl-text); }
.wl-se .wl-se-view .wt-glyph, .wl-se .wl-se-view .wt-glyph svg { width: 13px; height: 13px; }
.wl-ss { --ss-dice: var(--wl-warning); --ss-check: var(--wl-selection); --ss-change: var(--wl-success); --ss-story: color-mix(in srgb, var(--wl-warning) 35%, var(--wl-text-2)); --ss-stop: var(--wl-danger); --ss-code: var(--wl-text-3); --ss-look: var(--wl-highlight);
  flex: 1; min-width: 0; overflow: auto; padding: 16px 22px 28px; outline: none; }
.wl-ss-head { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; max-width: 920px; margin: 0 0 14px; }
.wl-se .wl-ss-head input { height: 32px; margin: 0; padding: 0 8px; border: 1px solid transparent; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font: inherit; transition: border-color var(--wl-quick) var(--wl-ease), background var(--wl-quick) var(--wl-ease); }
.wl-se .wl-ss-head input:hover { border-color: var(--wl-line); }
.wl-se .wl-ss-head input:focus { border-color: var(--wl-selection); background: var(--wl-inset); outline: none; box-shadow: 0 0 0 3px var(--wl-selection-soft); }
.wl-se .wl-ss-head .wl-ss-name { flex: 0 1 220px; min-width: 120px; font-size: 16px; font-weight: 600; }
.wl-se .wl-ss-head .wl-ss-said { flex: 1 1 320px; min-width: 200px; color: var(--wl-text-2); font-size: 13.5px; }
.wl-se .wl-ss-undo { display: inline-grid; place-items: center; width: 30px; height: 30px; margin: 0; padding: 0; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); cursor: pointer; }
.wl-se .wl-ss-undo:hover:not(:disabled) { background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-ss-undo:disabled { opacity: .35; cursor: default; }
.wl-ss-sec { max-width: 920px; }
.wl-ss-sec + .wl-ss-sec { margin-top: 18px; }
.wl-ss-k { margin: 0 0 8px; color: var(--wl-text-3); font-size: 11px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; }
.wl-ss-list { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; list-style: none; }
.wl-ss-item { display: flex; flex-direction: column; gap: 6px; }
.wl-ss-step { position: relative; display: grid; grid-template-columns: 14px 32px minmax(0, 1fr) auto 28px; align-items: center; gap: 10px; min-height: 48px; padding: 7px 8px 7px 10px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); --c: var(--ss-code); }
.wl-ss-step[data-tone="dice"] { --c: var(--ss-dice); } .wl-ss-step[data-tone="check"] { --c: var(--ss-check); } .wl-ss-step[data-tone="change"] { --c: var(--ss-change); }
.wl-ss-step[data-tone="story"] { --c: var(--ss-story); } .wl-ss-step[data-tone="stop"] { --c: var(--ss-stop); } .wl-ss-step[data-tone="look"] { --c: var(--ss-look); }
.wl-ss-step.is-else { min-height: 40px; background: transparent; box-shadow: none; }
.wl-ss-step.is-dragging { opacity: .45; }
.wl-ss-step.is-drop-before::before, .wl-ss-step.is-drop-after::after { content: ""; position: absolute; left: 6px; right: 6px; height: 2px; border-radius: var(--r-xs); background: var(--wl-selection); }
.wl-ss-step.is-drop-before::before { top: -5px; } .wl-ss-step.is-drop-after::after { bottom: -5px; }
.wl-ss-grip { display: grid; place-items: center; color: var(--wl-text-3); opacity: .45; cursor: grab; touch-action: none; }
.wl-ss-grip.is-blank { cursor: default; }
.wl-ss-step:hover .wl-ss-grip:not(.is-blank) { opacity: .9; }
.wl-ss .wl-ss-grip .wt-glyph, .wl-ss .wl-ss-grip svg { width: 14px; height: 14px; }
.wl-ss-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-md); background: color-mix(in srgb, var(--c) 14%, transparent); color: var(--c); }
.wl-ss .wl-ss-ic .wt-glyph, .wl-ss .wl-ss-ic svg { width: 16px; height: 16px; }
.wl-ss-text { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; color: var(--wl-text); font-size: 13.5px; line-height: 1.45; }
.wl-ss-w { white-space: nowrap; }
.wl-ss-step.is-else .wl-ss-text > .wl-ss-w:first-child { color: var(--wl-text-2); font-weight: 500; }
.wl-se .wl-ss-chip { display: inline-flex; align-items: center; gap: 5px; max-width: 100%; height: 26px; margin: 0; padding: 0 6px 0 9px; border: 0; border-radius: var(--r-sm); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line-strong); color: var(--wl-text); font: 600 13px/1 var(--wl-font-ui); white-space: nowrap; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), box-shadow var(--wl-quick) var(--wl-ease); }
.wl-se .wl-ss-chip > span:not(.wt-glyph) { overflow: hidden; text-overflow: ellipsis; }
.wl-se .wl-ss-chip:hover, .wl-se .wl-ss-chip[aria-expanded="true"] { background: var(--wl-raised); box-shadow: inset 0 0 0 1px var(--wl-selection); }
.wl-se .wl-ss-chip .wl-ss-caret, .wl-se .wl-ss-chip .wl-ss-caret svg { width: 11px; height: 11px; color: var(--wl-text-3); }
.wl-se .wl-ss-chip.mono { font-family: var(--wl-font-mono); font-size: 12.5px; }
.wl-se .wl-ss-chip.is-who { background: color-mix(in srgb, var(--ss-dice) 11%, var(--wl-surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ss-dice) 38%, transparent); }
.wl-se .wl-ss-chip.is-field { background: color-mix(in srgb, var(--ss-change) 11%, var(--wl-surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ss-change) 38%, transparent); }
.wl-se .wl-ss-chip.is-look { background: color-mix(in srgb, var(--ss-look) 11%, var(--wl-surface)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ss-look) 38%, transparent); }
.wl-se .wl-ss-chip.is-verb { background: transparent; box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); font-weight: 500; }
.wl-se .wl-ss-chip.is-words { height: auto; min-height: 26px; padding: 3px 10px; white-space: normal; text-align: left; font: 400 14px/1.45 var(--wl-font-reading); }
.wl-se .wl-ss-chip.is-words > span { display: inline; }
.wl-ss-q { color: var(--wl-text-3); }
.wl-ss-tok { margin: 0 1px; padding: 0 5px; border-radius: var(--r-sm); background: color-mix(in srgb, var(--ss-dice) 16%, transparent); color: var(--wl-text); font: 600 12.5px var(--wl-font-ui); white-space: nowrap; }
.wl-se .wl-ss-chip.is-start { gap: 6px; height: 26px; padding: 0 7px 0 8px; font-weight: 500; }
.wl-se .wl-ss-chip.is-start > .wt-glyph:first-child { color: var(--wl-text-2); }
.wl-ss-code { display: block; flex: 1 1 100%; max-height: 7.5em; margin: 0; padding: 7px 10px; overflow: hidden; border-radius: var(--r-sm); background: var(--wl-bg); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); font: 12px/1.6 var(--wl-font-mono); white-space: pre-wrap; overflow-wrap: anywhere; cursor: text; -webkit-mask-image: linear-gradient(180deg, currentcolor 75%, transparent); mask-image: linear-gradient(180deg, currentcolor 75%, transparent); }
.wl-ss-code:hover, .wl-ss-code:focus-visible { color: var(--wl-text); outline: none; box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wl-se .wl-ss-note { flex: 1; min-width: 160px; height: 28px; margin: 0; padding: 0 6px; border: 1px solid transparent; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text-2); font: italic 13.5px var(--wl-font-ui); }
.wl-se .wl-ss-note:hover { border-color: var(--wl-line); } .wl-se .wl-ss-note:focus { border-color: var(--wl-line-strong); outline: none; box-shadow: none; }
.wl-ss-res { display: inline-flex; align-items: center; gap: 6px; max-width: 260px; height: 24px; padding: 0 10px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--wl-success) 16%, transparent); color: var(--wl-success); font-size: 12px; font-weight: 600; white-space: nowrap; animation: wl-pop var(--wl-short) var(--wl-ease-out); }
.wl-ss-res > span { overflow: hidden; text-overflow: ellipsis; }
.wl-ss-res.is-skip { background: var(--wl-surface); color: var(--wl-text-3); font-weight: 500; }
.wl-ss-res.is-stop { background: color-mix(in srgb, var(--wl-warning) 16%, transparent); color: var(--wl-warning); }
.wl-ss-res.is-error { background: color-mix(in srgb, var(--wl-danger) 16%, transparent); color: var(--wl-danger); }
.wl-ss .wl-ss-res .wt-glyph, .wl-ss .wl-ss-res svg { width: 12px; height: 12px; }
.wl-se .wl-ss-more { display: inline-grid; place-items: center; width: 28px; height: 28px; margin: 0; padding: 0; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); cursor: pointer; grid-column: 5; }
.wl-se .wl-ss-more:hover, .wl-se .wl-ss-more[aria-expanded="true"] { background: var(--wl-surface); color: var(--wl-text); }
.wl-ss-branch { margin-left: 30px; padding-left: 14px; border-left: 1px solid color-mix(in srgb, var(--ss-check) 35%, var(--wl-line)); }
.wl-ss-none { padding: 10px 12px; border: 1px dashed var(--wl-line-strong); border-radius: var(--r-md); color: var(--wl-text-3); font-size: 12.5px; }
.wl-ss-none.is-drop-in { border-color: var(--wl-selection); background: var(--wl-selection-soft); }
.wl-ss-inline { list-style: none; }
.wl-se .wl-ss-mini { display: inline-flex; align-items: center; gap: 5px; height: 26px; margin: 0; padding: 0 9px; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); font-size: 12px; cursor: pointer; }
.wl-se .wl-ss-mini:hover, .wl-se .wl-ss-mini[aria-expanded="true"] { background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-ss-mini .wt-glyph, .wl-se .wl-ss-mini svg { width: 12px; height: 12px; }
.wl-ss-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; }
.wl-se .wl-ss-add { display: inline-flex; align-items: center; gap: 8px; height: 36px; margin: 0; padding: 0 14px; border: 1px dashed var(--wl-line-strong); border-radius: var(--r-md); background: transparent; box-shadow: none; color: var(--wl-text-2); font-size: 13px; font-weight: 600; cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), border-color var(--wl-quick) var(--wl-ease); }
.wl-se .wl-ss-add:hover, .wl-se .wl-ss-add[aria-expanded="true"] { border-style: solid; background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-ss-add.is-quiet { border-color: transparent; color: var(--wl-text-3); font-weight: 500; }
.wl-ss-unread { display: grid; justify-items: start; gap: 10px; max-width: 520px; padding: 18px; border-radius: var(--r-lg); background: var(--wl-inset); color: var(--wl-text-2); font-size: 13px; line-height: 1.55; }
.wl-ss-unread p { margin: 0; }
.wl-ss-codebox { display: grid; gap: 8px; padding: 10px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wl-se textarea.wl-ss-codearea { width: 100%; box-sizing: border-box; margin: 0; padding: 10px 12px; border: 0; border-radius: var(--r-sm); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text); font: 12.5px/1.65 var(--wl-font-mono); resize: vertical; tab-size: 2; white-space: pre; }
.wl-se textarea.wl-ss-codearea:focus { outline: none; box-shadow: inset 0 0 0 1px var(--wl-selection); }
.wl-ss-codebar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.wl-ss-codebar .wl-ss-hint { flex: 1; min-width: 160px; }
/* Popovers: a small panel under a blank, the Add a step menu, and a sheet from the bottom on a phone. */
.wl-ss-pop { position: fixed; z-index: 400; left: -9999px; top: 0; box-sizing: border-box; min-width: 220px; max-width: min(380px, calc(100vw - 16px)); max-height: min(70vh, 560px); overflow: auto; padding: 6px; border-radius: var(--r-lg); background: var(--wl-raised); box-shadow: 0 0 0 1px var(--wl-line-strong), var(--wl-elev-pop); color: var(--wl-text); font: 13px/1.4 var(--wl-font-ui); animation: wl-pop var(--wl-short) var(--wl-ease-out); }
.wl-ss-pop.is-add { max-width: min(760px, calc(100vw - 16px)); padding: 8px; }
.wl-ss-pop.is-words { width: min(420px, calc(100vw - 16px)); max-width: none; }
.wl-ss-pop.is-sheet { left: 0 !important; right: 0; top: auto !important; bottom: 0; max-width: none; max-height: 78vh; border-radius: var(--r-lg) var(--r-lg) 0 0; padding: 10px 10px calc(10px + env(safe-area-inset-bottom)); animation: wl-rise var(--wl-short) var(--wl-ease-out); }
.wl-ss-pop .wl-ss-g { padding: 8px 10px 4px; color: var(--wl-text-3); font-size: 10.5px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; }
.wl-ss-pop button { font-family: inherit; }
.wl-ss-pop .wl-ss-it { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 2px 10px; width: 100%; min-height: 32px; margin: 0; padding: 6px 10px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 13px; text-align: left; cursor: pointer; }
.wl-ss-pop .wl-ss-it:hover:not(:disabled), .wl-ss-pop .wl-ss-it:focus-visible { background: var(--wl-surface); outline: none; }
.wl-ss-pop .wl-ss-it.is-on { color: var(--wl-text); font-weight: 600; }
.wl-ss-pop .wl-ss-it:disabled { color: var(--wl-text-3); cursor: default; }
.wl-ss-pop .wl-ss-it small { color: var(--wl-text-3); font-size: 11.5px; font-weight: 400; }
.wl-ss-pop .wl-ss-tick, .wl-ss-pop .wl-ss-tick svg { width: 13px; height: 13px; color: var(--wl-success); }
.wl-ss-form { display: grid; gap: 6px; padding: 6px 6px 8px; }
.wl-ss-form.is-row { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; align-items: end; }
.wl-ss-form label { display: grid; gap: 4px; }
.wl-ss-form .wl-ss-g { padding: 0; }
.wl-ss-pop input, .wl-ss-pop textarea { box-sizing: border-box; width: 100%; min-width: 0; margin: 0; padding: 7px 9px; border: 1px solid var(--wl-line); border-radius: var(--r-sm); background: var(--wl-inset); box-shadow: none; color: var(--wl-text); font: 13px/1.45 var(--wl-font-ui); }
.wl-ss-pop textarea { resize: vertical; font-family: var(--wl-font-reading); font-size: 14px; }
.wl-ss-pop input:focus, .wl-ss-pop textarea:focus { border-color: var(--wl-selection); outline: none; box-shadow: none; }
.wl-ss-hint { color: var(--wl-text-3); font-size: 11.5px; }
.wl-ss-hint:empty { display: none; }
.wl-ss-hint.is-bad { color: var(--wl-danger); }
.wl-ss-pop .wl-ss-done { justify-self: end; height: 30px; margin: 0; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: var(--wl-accent); box-shadow: none; color: var(--wl-on-accent); font-size: 12.5px; font-weight: 600; cursor: pointer; }
.wl-ss-presets { display: flex; flex-wrap: wrap; gap: 5px; padding: 2px 6px 8px; }
.wl-ss-pop .wl-ss-preset { height: 26px; margin: 0; padding: 0 9px; border: 0; border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); font: 12px var(--wl-font-mono); cursor: pointer; }
.wl-ss-pop .wl-ss-preset.is-tok { font-family: var(--wl-font-ui); font-weight: 600; }
.wl-ss-pop .wl-ss-preset:hover, .wl-ss-pop .wl-ss-preset.is-on { background: var(--wl-raised); box-shadow: inset 0 0 0 1px var(--wl-selection); color: var(--wl-text); }
.wl-ss-list-pop { display: grid; }
.wl-ss-kinds { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px 6px; }
.wl-ss-col { display: grid; align-content: start; gap: 1px; }
.wl-ss-pop .wl-ss-kind { --c: var(--wl-text-3); display: grid; grid-template-columns: 28px minmax(0, 1fr); align-items: center; gap: 9px; width: 100%; margin: 0; padding: 6px 8px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); text-align: left; cursor: pointer; }
.wl-ss-pop .wl-ss-kind[data-tone="dice"] { --c: var(--wl-warning); } .wl-ss-pop .wl-ss-kind[data-tone="check"] { --c: var(--wl-selection); } .wl-ss-pop .wl-ss-kind[data-tone="change"] { --c: var(--wl-success); }
.wl-ss-pop .wl-ss-kind[data-tone="story"] { --c: color-mix(in srgb, var(--wl-warning) 35%, var(--wl-text-2)); } .wl-ss-pop .wl-ss-kind[data-tone="stop"] { --c: var(--wl-danger); } .wl-ss-pop .wl-ss-kind[data-tone="code"] { --c: var(--wl-text-3); } .wl-ss-pop .wl-ss-kind[data-tone="look"] { --c: var(--wl-highlight); }
.wl-ss-pop .wl-ss-kind:hover, .wl-ss-pop .wl-ss-kind:focus { background: var(--wl-surface); outline: none; box-shadow: none; }
.wl-ss-pop .wl-ss-kind, .wl-ss-pop .wl-ss-it { height: auto; }
.wl-ss-pop .wl-ss-it:focus { outline: none; box-shadow: none; background: var(--wl-surface); }
.wl-ss-pop .wl-ss-kind > span:last-child { min-width: 0; }
.wl-ss-pop .wl-ss-kind, .wl-ss-pop .wl-ss-it small { white-space: normal; }
.wl-ss-pop:focus { outline: none; }
.wl-ss-pop .wl-ss-presets { padding: 2px 0 4px; }
.wl-ss-pop .wl-ss-kind .wl-ss-ic { width: 28px; height: 28px; border-radius: var(--r-md); background: color-mix(in srgb, var(--c) 15%, transparent); color: var(--c); display: grid; place-items: center; }
.wl-ss-pop .wl-ss-kind .wl-ss-ic svg, .wl-ss-pop .wl-ss-kind .wl-ss-ic .wt-glyph { width: 15px; height: 15px; }
.wl-ss-pop .wl-ss-kind b { display: block; font-size: 13px; font-weight: 600; }
.wl-ss-pop .wl-ss-kind small { display: block; color: var(--wl-text-3); font-size: 11.5px; line-height: 1.35; }
/* Show an effect: a tile per effect, played in place when pointed at. */
.wl-ss-pop.is-fx { width: min(440px, calc(100vw - 16px)); max-width: none; padding: 8px; }
.wl-ss-fx-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; padding: 2px 2px 6px; }
.wl-ss-pop .wl-ss-fx { display: grid; justify-items: center; gap: 6px; height: auto; margin: 0; padding: 8px 4px 7px; border: 0; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--wl-text-2); cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), box-shadow var(--wl-quick) var(--wl-ease); }
.wl-ss-pop .wl-ss-fx:hover, .wl-ss-pop .wl-ss-fx:focus-visible { background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line-strong); color: var(--wl-text); outline: none; }
.wl-ss-pop .wl-ss-fx.is-on { box-shadow: inset 0 0 0 1px var(--wl-selection); color: var(--wl-text); }
.wl-ss-fx-stage { display: grid; place-items: center; width: 52px; height: 40px; border-radius: var(--r-sm); background: var(--wl-bg); }
.wl-ss-fx-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--wl-raised); }
.wl-ss-fx-name { max-width: 100%; overflow: hidden; font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.wl-ss-fx-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 4px 2px; border-top: 1px solid var(--wl-line); }
.wl-ss-hear-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2px; }
.wl-ss-pop .wl-ss-hear { display: inline-grid; place-items: center; width: 28px; height: 28px; margin: 0 4px 0 0; padding: 0; border: 0; border-radius: var(--r-pill); background: transparent; box-shadow: none; color: var(--wl-text-3); cursor: pointer; }
.wl-ss-pop .wl-ss-hear:hover, .wl-ss-pop .wl-ss-hear:focus-visible { background: var(--wl-surface); color: var(--wl-highlight); outline: none; }
.wl-ss-pop .wl-ss-hear svg, .wl-ss-pop .wl-ss-hear .wt-glyph { width: 13px; height: 13px; }
.wl-ss-later { margin: 8px 4px 2px; padding: 8px 10px; border-radius: var(--r-sm); background: var(--wl-inset); color: var(--wl-text-3); font-size: 12px; }
@container (max-width: 760px) { .wl-ss-kinds { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) { .wl-ss-kinds { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) {
  .wl-ss-fx-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .wl-ss { padding: 12px 12px 24px; }
  .wl-ss-step { grid-template-columns: 30px minmax(0, 1fr) 28px; gap: 8px; padding: 7px 6px 7px 8px; }
  .wl-ss-grip { display: none; }
  .wl-ss-res { grid-column: 2; grid-row: 2; justify-self: start; }
  .wl-se .wl-ss-more { grid-column: 3; grid-row: 1; }
  .wl-ss-branch { margin-left: 12px; padding-left: 10px; }
  .wl-ss-kinds { grid-template-columns: minmax(0, 1fr); }
  .wl-se .wl-se-view > span:not(.wt-glyph) { display: none; }
}
@media (prefers-reduced-motion: reduce) { .wl-ss-res, .wl-ss-pop, .wl-ss-pop.is-sheet { animation: wl-fade 150ms linear; } .wl-se .wl-se-view, .wl-se .wl-ss-chip, .wl-se .wl-ss-add { transition: none; } }

/* Write one in code (D-156): a script of the world's, on this type, in its own tab. */
.wt-sc-own { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin: 12px 0 0; color: var(--wl-text-3); font-size: 12px; }

/* The code and the line to try show focus on their own part, not the shell's ring (atlas-system.css). */
body .wl-se textarea.wl-se-editor:is(:focus, :focus-visible), body .wl-se .wl-se-prompt input:is(:focus, :focus-visible) { border: 0; outline: none; box-shadow: none; }
.wl-se-code:focus-within .wl-se-lines { color: var(--wl-text-2); }
.wl-se-prompt { padding-right: 64px; transition: background var(--wl-quick) var(--wl-ease); }
.wl-se-prompt:focus-within { background: var(--wl-surface); }
.wl-se-prompt:focus-within .wl-se-caret { color: var(--wl-selection); }

/* Or say it (D-158): a sentence to Boris at the foot of the steps, and his change waiting over them. */
.wl-se .wl-ss-say { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 12px; align-items: center; margin: 14px 0 0; padding: 7px 7px 7px 14px; border-radius: var(--r-lg); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); transition: box-shadow var(--wl-quick) var(--wl-ease); }
.wl-se .wl-ss-say:focus-within, .wl-se .wl-ss-say.is-typed { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--wl-selection) 55%, var(--wl-line)); }
.wl-se .wl-ss-say .wt-orbis-blob { --size: 22px; }
.wl-se .wl-ss-say textarea { display: block; width: 100%; min-height: 22px; max-height: 140px; margin: 0; padding: 5px 0; border: 0; border-radius: 0; background: none; box-shadow: none; color: var(--wl-text); font: inherit; font-size: 13.5px; line-height: 1.5; resize: none; }
.wl-se .wl-ss-say textarea:focus { outline: none; box-shadow: none; }
.wl-se .wl-ss-say textarea::placeholder { color: var(--wl-text-3); }
.wl-se .wl-ss-say-go { display: inline-grid; place-items: center; width: 32px; height: 32px; margin: 0; padding: 0; border: 0; border-radius: 50%; background: var(--wl-raised); box-shadow: none; color: var(--wl-text-3); cursor: pointer; transition: background var(--wl-quick) var(--wl-ease), color var(--wl-quick) var(--wl-ease); }
.wl-se .wl-ss-say.is-typed .wl-ss-say-go:not(:disabled) { background: var(--wl-accent); color: var(--wl-on-accent); }
.wl-se .wl-ss-say-go:disabled { cursor: default; }
.wl-se .wl-ss-say-go svg { width: 15px; height: 15px; }
.wl-se .wl-ss-say.is-working { padding-block: 10px; }
.wl-ss-say-words { display: grid; gap: 2px; min-width: 0; font-size: 13px; color: var(--wl-text); }
.wl-ss-say-words small { overflow: hidden; color: var(--wl-text-3); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.wl-ss-say-spin { display: block; width: 14px; height: 14px; margin-inline-end: 9px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--wl-selection) 30%, transparent); border-top-color: var(--wl-selection); animation: wt-sc-spin .8s linear infinite; }
.wl-se-boris { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; padding: 8px 18px; border-bottom: 1px solid var(--wl-line); background: color-mix(in srgb, var(--wl-selection) 7%, transparent); animation: wl-fade var(--wl-short) var(--wl-ease); }
.wl-se-boris .wt-orbis-blob { --size: 20px; flex: none; }
.wl-se-boris-words { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; flex: 1 1 260px; min-width: 0; color: var(--wl-text-2); font-size: 12.5px; }
.wl-se-boris-words b { color: var(--wl-text); font-weight: 600; }
.wl-se-boris-acts { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.wl-se-boris-state { margin-inline-end: 4px; color: var(--wl-text-3); font-size: 12px; white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { .wl-ss-say-spin { animation-duration: 2.4s; } .wl-se-boris { animation: none; } .wl-se .wl-ss-say, .wl-se .wl-ss-say-go { transition: none; } }

/* The script page (D-162): one bar, one column to read from the top, and Try it beside it. Form reads as a short
   form (who and when, what happens, how it looks) with every value a word to click; Code is the code with its
   log and a line to try under it. Below 960px wide, Try it goes under the column. */
.wl-se-surface { container-type: inline-size; }
.wl-se { position: relative; height: 100%; }
.wl-se-bar { flex-wrap: nowrap; gap: 10px; min-height: 60px; padding: 10px 20px 10px 28px; }
.wl-se-crumbs { gap: 8px; min-width: 0; font-size: 14.5px; }
.wl-se .wl-se-crumb { display: inline-flex; align-items: center; gap: 8px; padding: 2px 4px; font-size: 14.5px; }
.wl-se .wl-se-crumb .wt-glyph, .wl-se .wl-se-crumb svg { width: 15px; height: 15px; }
.wl-se-sep { opacity: .55; }
.wl-se-crumbs b { color: var(--wl-text); font-size: 14.5px; }
.wl-se-state { gap: 7px; height: auto; margin-left: 6px; padding: 0; background: none; color: var(--wl-text-3); font-size: 13px; }
.wl-se-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--wl-success); }
.wl-se-state[data-state="dirty"]::before { background: var(--wl-warning); }
.wl-se-state[data-state="error"] { color: var(--wl-danger); }
.wl-se-state[data-state="error"]::before { background: var(--wl-danger); }
.wl-se-state[data-state="busy"]::before { background: var(--wl-text-3); }
.wl-se-views { flex: none; padding: 3px; border-radius: var(--r-md); }
.wl-se .wl-se-view { height: 28px; padding: 0 12px; border-radius: var(--r-sm); font-size: 13px; }
.wl-se .wl-se-view .wt-glyph, .wl-se .wl-se-view .wt-glyph svg { width: 15px; height: 15px; }
.wl-se .wl-se-icon { width: 34px; height: 34px; }
.wl-se .wl-se-icon .wt-glyph, .wl-se .wl-se-icon svg { width: 17px; height: 17px; }
.wl-se .wl-se-btn { height: 34px; padding: 0 16px; font-size: 13px; }
.wl-se .wl-se-btn.is-cta.is-quiet, .wl-se .wl-se-btn.is-cta.is-quiet:disabled { background: var(--wl-raised); color: var(--wl-text-3); opacity: 1; }
.wl-se .wl-se-btn.is-line { border: 1px solid var(--wl-line-strong); background: transparent; color: var(--wl-text-2); }
.wl-se .wl-se-btn.is-line:hover { background: var(--wl-surface); color: var(--wl-text); }
.wl-se-page { flex: 1; min-height: 0; overflow: auto; }
.wl-se-cols { display: grid; grid-template-columns: minmax(0, 640px) 330px; justify-content: center; gap: 56px; padding: 40px 32px 96px; }
.wl-se[data-view="code"] .wl-se-cols { grid-template-columns: minmax(0, 780px) 330px; gap: 40px; padding-top: 28px; }
.wl-se-main { min-width: 0; }
.wl-se-side { position: sticky; top: 24px; align-self: start; display: grid; gap: 16px; min-width: 0; }
.wl-se-main > .wl-se-boris { margin: 0 0 24px; border: 0; border-radius: var(--r-lg); }

/* Form: the title, then parts with a small heading each. */
.wl-se .wl-ss { flex: none; overflow: visible; padding: 0; }
.wl-ss-head { position: relative; display: block; max-width: none; margin: 0; padding-right: 40px; }
.wl-se .wl-ss-head .wl-ss-name { display: block; width: 100%; height: auto; min-width: 0; margin: 0 0 0 -8px; padding: 2px 8px; font: 600 var(--t-title-page)/1.3 var(--wl-font-ui); letter-spacing: 0; }
.wl-se .wl-ss-head textarea.wl-ss-said { display: block; box-sizing: border-box; width: calc(100% + 16px); min-height: 0; margin: 8px 0 0 -8px; padding: 4px 8px; overflow: hidden; border: 1px solid transparent; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text-2); font: 400 16px/1.55 var(--wl-font-ui); resize: none; }
.wl-se .wl-ss-head textarea.wl-ss-said:hover { border-color: var(--wl-line); }
.wl-se .wl-ss-head textarea.wl-ss-said:focus { border-color: var(--wl-selection); background: var(--wl-inset); outline: none; box-shadow: 0 0 0 3px var(--wl-selection-soft); }
.wl-se .wl-ss-head .wl-ss-undo { position: absolute; top: 6px; right: 0; }
.wl-se-problems:empty { display: none; }
.wl-se-problems { display: grid; gap: 6px; margin-top: 18px; }
.wl-se-flag { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 10px 12px; border-radius: var(--r-md); background: color-mix(in srgb, var(--wl-warning) 9%, transparent); color: var(--wl-text-2); font-size: 13px; }
.wl-se-flag > .wt-glyph { color: var(--wl-warning); }
.wl-se-flag.is-error { background: color-mix(in srgb, var(--wl-danger) 10%, transparent); }
.wl-se-flag.is-error > .wt-glyph { color: var(--wl-danger); }
.wl-se-flag > span { flex: 1 1 240px; min-width: 0; }
.wl-se .wl-ss-sec { max-width: none; margin-top: 40px; }
.wl-se .wl-ss-sec + .wl-ss-sec { margin-top: 40px; }
.wl-se .wl-ss-k { margin: 0 0 8px; font-size: 11.5px; letter-spacing: .13em; }
.wl-ss-rows { border-bottom: 1px solid var(--wl-line); }
.wl-ss-row { display: grid; grid-template-columns: 120px minmax(0, 1fr); align-items: center; gap: 16px; min-height: 48px; padding: 7px 0; border-top: 1px solid var(--wl-line); }
.wl-ss-row-k { color: var(--wl-text-3); font-size: 14px; }
.wl-ss-row-v { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; min-width: 0; color: var(--wl-text); font-size: 14px; }
.wl-ss-row-v.is-list { display: grid; justify-items: start; gap: 2px; }
.wl-ss-dim { color: var(--wl-text-3); font-size: 14px; }
.wl-se .wl-ss-row .wl-se-type { height: 28px; font-size: 13.5px; }
.wl-se .wl-se-only { display: inline-flex; align-items: center; gap: 6px; height: 28px; margin: 0; padding: 0 4px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 14px; cursor: pointer; }
.wl-se .wl-se-only.is-quiet { color: var(--wl-text-3); }
.wl-se .wl-se-only:hover, .wl-se .wl-se-only[aria-expanded="true"] { background: var(--wl-surface); }
.wl-se .wl-se-only .wt-glyph, .wl-se .wl-se-only svg { width: 12px; height: 12px; color: var(--wl-text-3); }
.wl-se select.wl-se-add { height: 28px; }
.wl-se-note { color: var(--wl-text-3); font-size: 13px; }

/* Words to click: plain text with a dotted line under it, not boxes; the row's own picks keep a small arrow. */
.wl-se .wl-ss .wl-ss-chip { height: auto; min-height: 0; padding: 1px 2px; border-radius: var(--r-xs); background: transparent; box-shadow: none; color: var(--wl-text); font: 500 15px/1.5 var(--wl-font-ui); text-decoration: underline dashed color-mix(in srgb, var(--wl-text-3) 75%, transparent); text-decoration-thickness: 1px; text-underline-offset: 5px; }
.wl-se .wl-ss .wl-ss-chip:hover, .wl-se .wl-ss .wl-ss-chip[aria-expanded="true"] { background: var(--wl-surface); box-shadow: none; text-decoration-color: var(--wl-text-2); }
.wl-se .wl-ss .wl-ss-chip .wl-ss-caret { display: none; }
.wl-se .wl-ss .wl-ss-chip.mono { font: 500 14px/1.5 var(--wl-font-mono); }
.wl-se .wl-ss .wl-ss-chip.is-words { padding: 1px 2px; color: var(--wl-text-2); font: 400 15px/1.6 var(--wl-font-ui); text-decoration: none; }
.wl-se .wl-ss .wl-ss-chip.is-words .wl-ss-tok { margin: 0 1px; padding: 0; background: none; color: var(--wl-text); font: 500 15px/1.6 var(--wl-font-ui); text-decoration: underline dashed color-mix(in srgb, var(--wl-text-3) 75%, transparent); text-underline-offset: 5px; white-space: normal; }
.wl-se .wl-ss .wl-ss-chip.is-verb { color: var(--wl-text); font-weight: 500; }
.wl-se .wl-ss .wl-ss-chip.is-start { gap: 8px; padding: 3px 6px; margin-left: -6px; text-decoration: none; font-size: 14px; }
.wl-se .wl-ss .wl-ss-chip.is-start .wl-ss-caret { display: inline-flex; }
.wl-se .wl-ss .wl-ss-chip.is-start.is-quiet { color: var(--wl-text-3); }
.wl-se .wl-ss .wl-ss-chip.is-start > .wt-glyph:first-child, .wl-se .wl-ss .wl-ss-chip.is-start > .wt-glyph:first-child svg { width: 16px; height: 16px; color: var(--wl-text-2); }
.wl-ss-w { color: var(--wl-text); }

/* What happens: numbered steps between hairlines; inside an If, a small icon instead of the number. */
.wl-se .wl-ss-list { gap: 0; }
.wl-se .wl-ss-step { grid-template-columns: 26px minmax(0, 1fr) auto 28px; align-items: start; gap: 14px; min-height: 0; padding: 13px 0; border-radius: 0; background: transparent; box-shadow: none; border-top: 1px solid var(--wl-line); }
.wl-se .wl-ss-sec.is-what > .wl-ss-list { counter-reset: wl-step; border-bottom: 1px solid var(--wl-line); }
.wl-se .wl-ss-sec.is-what > .wl-ss-list > .wl-ss-item { counter-increment: wl-step; }
.wl-se .wl-ss-grip { position: absolute; left: -26px; top: 15px; opacity: 0; }
.wl-se .wl-ss-step:hover .wl-ss-grip:not(.is-blank) { opacity: .7; }
.wl-se .wl-ss-ic { width: 24px; height: 24px; margin-top: 1px; border-radius: 50%; background: var(--wl-raised); color: var(--c); }
.wl-se .wl-ss .wl-ss-ic .wt-glyph, .wl-se .wl-ss .wl-ss-ic svg { width: 13px; height: 13px; }
.wl-se .wl-ss-sec.is-what > .wl-ss-list > .wl-ss-item > .wl-ss-step > .wl-ss-ic > * { display: none; }
.wl-se .wl-ss-sec.is-what > .wl-ss-list > .wl-ss-item > .wl-ss-step > .wl-ss-ic::before { content: counter(wl-step); color: var(--wl-text-3); font-size: 12px; font-weight: 600; }
.wl-se .wl-ss-text { gap: 4px 5px; padding-top: 1px; font-size: 15px; line-height: 1.5; }
.wl-se .wl-ss-res { align-self: center; height: auto; padding: 0; background: none; font-size: 13px; font-weight: 500; }
.wl-se .wl-ss-res.is-skip, .wl-se .wl-ss-res.is-stop, .wl-se .wl-ss-res.is-error { background: none; }
.wl-se .wl-ss-more { align-self: center; opacity: .55; }
.wl-se .wl-ss-step:hover .wl-ss-more, .wl-se .wl-ss-more[aria-expanded="true"], .wl-se .wl-ss-more:focus-visible { opacity: 1; }
.wl-se .wl-ss-branch { margin-left: 12px; padding-left: 26px; border-left: 1px solid var(--wl-line); }
.wl-se .wl-ss-branch .wl-ss-step:first-child { border-top: 0; }
.wl-se .wl-ss-step.is-else { padding: 9px 0; }
.wl-se .wl-ss-inline { padding: 4px 0 8px; }
.wl-se .wl-ss-none { margin: 6px 0; padding: 12px 14px; border-radius: var(--r-md); font-size: 13.5px; }
.wl-se .wl-ss-code { font-size: 12.5px; }
.wl-se .wl-ss-foot { margin-top: 12px; }
.wl-se .wl-ss-add { height: 34px; padding: 0 12px 0 8px; border: 0; border-radius: var(--r-sm); color: var(--wl-text-3); font-weight: 500; font-size: 14px; }
.wl-se .wl-ss-add:hover, .wl-se .wl-ss-add[aria-expanded="true"] { background: var(--wl-surface); color: var(--wl-text); }
.wl-se .wl-ss-add .wt-glyph, .wl-se .wl-ss-add svg { width: 16px; height: 16px; }
.wl-se .wl-ss-say { margin-top: 18px; }
/* A reason it can't be done, in its row: a line each, without numbers. */
.wl-se .wl-ss-row-v .wl-ss-list { width: 100%; }
.wl-se .wl-ss-row-v .wl-ss-step { grid-template-columns: minmax(0, 1fr) auto 28px; padding: 4px 0; border-top: 0; }
.wl-se .wl-ss-row-v .wl-ss-ic { display: none; }
.wl-se .wl-ss-row-v .wl-ss-text { font-size: 14px; }
.wl-se .wl-ss-row-v .wl-ss .wl-ss-chip, .wl-se .wl-ss-row-v .wl-ss-chip { font-size: 14px; }
.wl-se .wl-ss-row-v .wl-ss-mini { margin-left: -9px; }

/* Looks like: a tile to see it, its name to change, and over whom. */
.wl-ss-looks { border-top: 1px solid var(--wl-line); border-bottom: 1px solid var(--wl-line); }
.wl-ss-looks > .wl-ss-dim { margin: 0; padding: 14px 0; font-size: 14px; }
.wl-ss-look { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto 28px; align-items: center; gap: 16px; padding: 12px 0; }
.wl-ss-look + .wl-ss-look { border-top: 1px solid var(--wl-line); }
.wl-se .wl-ss-look-tile { display: grid; place-items: center; width: 56px; height: 56px; margin: 0; padding: 0; border: 0; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); color: var(--ss-look); cursor: pointer; }
.wl-se .wl-ss-look-tile:hover { box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wl-se .wl-ss-look-tile .wl-ss-fx-dot { width: 16px; height: 16px; }
.wl-se .wl-ss-look-tile .wt-glyph, .wl-se .wl-ss-look-tile svg { width: 20px; height: 20px; }
.wl-ss-look-words { display: grid; gap: 2px; min-width: 0; }
.wl-se .wl-ss .wl-ss-chip.is-name { justify-self: start; font-size: 15.5px; font-weight: 600; }
.wl-ss-look-line { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 5px; color: var(--wl-text-3); font-size: 13.5px; }
.wl-ss-look-line .wl-ss-w { color: var(--wl-text-3); }
.wl-se .wl-ss-look-line .wl-ss-chip { font-size: 13.5px; color: var(--wl-text-2); }

/* Try it: a card for the file it's on, who and where, then Try; what happened shows as a game shows it. */
.wl-se-try { padding: 18px; border-radius: var(--r-xl); background: var(--wl-surface); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wl-se-try-head { display: flex; align-items: center; gap: 8px; color: var(--wl-text); }
.wl-se-try-head b { font-size: 15px; font-weight: 600; }
.wl-se-try-head small { margin-left: auto; color: var(--wl-text-3); font-size: 12px; }
.wl-se-try-head > .wt-glyph, .wl-se-try-head > .wt-glyph svg { width: 16px; height: 16px; color: var(--wl-text-2); }
.wl-se-try-wait { margin: 16px 0 4px; color: var(--wl-text-3); font-size: 13px; }
.wl-se .wl-se-try-card { display: grid; grid-template-columns: 52px minmax(0, 1fr) 14px; align-items: center; gap: 12px; width: 100%; height: auto; margin: 16px 0 6px; padding: 10px; border: 0; border-radius: var(--r-md); background: var(--wl-raised); box-shadow: none; color: var(--wl-text); text-align: left; cursor: pointer; }
.wl-se .wl-se-try-card:hover, .wl-se .wl-se-try-card[aria-expanded="true"] { box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wl-se-try-pic { width: 52px; height: 52px; border-radius: var(--r-md); object-fit: cover; }
.wl-se-try-pic.is-blank, .wl-se-try-face.is-blank { display: grid; place-items: center; background: var(--wl-surface); color: var(--wl-text-3); }
.wl-se-try-words { display: grid; gap: 2px; min-width: 0; }
.wl-se-try-words b { overflow: hidden; font-size: 14.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.wl-se-try-words small { overflow: hidden; color: var(--wl-text-3); font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.wl-se-try-row { display: grid; grid-template-columns: 48px minmax(0, 1fr); align-items: center; min-height: 44px; border-bottom: 1px solid var(--wl-line); }
.wl-se-try-row .wl-se-k { margin: 0; font-size: 13.5px; letter-spacing: 0; }
.wl-se .wl-se-try-pick { display: inline-flex; align-items: center; gap: 9px; justify-self: start; max-width: 100%; height: 34px; margin: 0 0 0 -6px; padding: 0 8px 0 6px; border: 0; border-radius: var(--r-sm); background: transparent; box-shadow: none; color: var(--wl-text); font-size: 14px; cursor: pointer; }
.wl-se .wl-se-try-pick > span:not(.wt-glyph):not(.wl-se-try-face) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wl-se .wl-se-try-pick:hover, .wl-se .wl-se-try-pick[aria-expanded="true"] { background: var(--wl-raised); }
.wl-se-try-face { flex: none; width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.wl-se-try-face.is-blank .wt-glyph, .wl-se-try-face.is-blank svg { width: 12px; height: 12px; }
.wl-se .wl-se-try-card .wl-ss-caret, .wl-se .wl-se-try-pick .wl-ss-caret, .wl-se .wl-se-try-card .wl-ss-caret svg, .wl-se .wl-se-try-pick .wl-ss-caret svg { width: 12px; height: 12px; color: var(--wl-text-3); }
.wl-se-try-out { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--wl-line); }
.wl-se-try-out[hidden] { display: none; }
.wl-se-told { margin: 0 0 4px; color: var(--wl-text); font: 400 16px/1.5 var(--wl-font-reading); }
.wl-se-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 2px; }
.wl-se-chip { display: inline-flex; align-items: center; min-height: 26px; padding: 2px 10px; border-radius: var(--r-lg); background: var(--wl-raised); color: var(--wl-text); font-size: 12.5px; line-height: 1.35; }
.wl-se-chip.is-roll { color: var(--wl-text-2); }
.wl-se-try-line { display: flex; align-items: flex-start; gap: 8px; margin: 6px 0 0; color: var(--wl-text-2); font-size: 13px; line-height: 1.5; }
.wl-se-try-line > .wt-glyph { margin-top: 3px; color: var(--wl-warning); }
.wl-se-try-line.is-error, .wl-se-try-line.is-error > .wt-glyph { color: var(--wl-danger); }
.wl-se-try-line.is-note, .wl-se-try-line.is-run { color: var(--wl-text-3); font-size: 12.5px; }
.wl-se-try-sum, .wl-se-try-note { display: block; margin-top: 10px; color: var(--wl-text-3); font-size: 12px; }
.wl-se-try-out .wl-se-line.is-ask { margin: 10px 0 0; padding-left: 22px; font-size: 13px; }
/* A script's card in Try it (D-172): the card as a game shows it, full width. */
.wl-se-line.is-card { display: block; margin: 10px 0 6px; padding-left: 0; line-height: normal; }
.wl-se-try-out .wl-se-line.is-card { margin: 10px 0 0; padding-left: 0; }
.wl-se .wl-se-try-go { justify-content: center; width: 100%; height: 40px; margin-top: 16px; border-radius: var(--r-2xl); font-size: 14px; }
.wl-se .wl-se-try-game { justify-content: center; width: 100%; height: 36px; margin-top: 8px; border-radius: var(--r-xl); }
.wl-se .wl-se-try-game > .wt-glyph { color: inherit; }

/* Code: what it's on, the code, and under it the log and the line to try. */
.wl-se[data-view="code"] .wl-se-on { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 14px; color: var(--wl-text-2); font-size: 13.5px; }
.wl-se[data-view="code"] .wl-se-on > .wl-se-k { margin-right: 6px; font-size: 13.5px; }
.wl-se[data-view="code"] .wl-se-code { overflow: hidden; border-radius: var(--r-lg); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wl-se[data-view="code"] .wl-se-lines { padding-top: 16px; background: transparent; border-right-color: var(--wl-line); font-size: 13px; line-height: 1.75; }
.wl-se .wl-se-lines, .wl-se .wl-se-ink { overflow: clip; }
.wl-se .wl-se-lines > span { display: block; }
.wl-se[data-view="code"] textarea.wl-se-editor { padding: 16px 18px; font-size: 13px; line-height: 1.75; }
.wl-se-test { display: flex; flex-direction: column; height: 260px; margin-top: 14px; overflow: hidden; border-radius: var(--r-lg); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wl-se-test-bar { flex-wrap: nowrap; gap: 8px; padding: 6px 8px 6px 10px; }
.wl-se-help { padding: 16px 18px 20px; border-radius: var(--r-xl); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }

/* The code in colour (D-162, D-339): the box is see-through over a layer that draws the same text, so its size, gaps
   and font match the box's. Midnight Prism's light split as a prism, the same hues in every theme, bright on dark ones
   and deep on pale ones (--wl-pale): words of the language ice blue, calls glacier, fields lilac, text in quotes mint,
   numbers and true or false gold, signs a soft rose, brackets and commas quiet, notes faint and leaning. A type's Code
   (code-view.mjs) takes the same: tags as the language's words, attributes and CSS properties as fields, selectors as
   calls, sizes and #colours as numbers. */
.wl-se, .wt-ws-code {
  --wl-ink-l: calc(0.83 - 0.35 * var(--wl-pale, 0)); --wl-ink-chroma: calc(0.105 + 0.03 * var(--wl-pale, 0));
  --wl-ink-k: oklch(calc(var(--wl-ink-l) - 0.04) calc(var(--wl-ink-chroma) + 0.025) 264);
  --wl-ink-f: oklch(calc(var(--wl-ink-l) + 0.02) var(--wl-ink-chroma) 208);
  --wl-ink-p: oklch(var(--wl-ink-l) var(--wl-ink-chroma) 308);
  --wl-ink-s: oklch(var(--wl-ink-l) var(--wl-ink-chroma) 160);
  --wl-ink-n: oklch(calc(var(--wl-ink-l) + 0.01) var(--wl-ink-chroma) 78);
  --wl-ink-o: oklch(calc(var(--wl-ink-l) - 0.06) calc(var(--wl-ink-chroma) + 0.035) 14);
}
.wl-se-well { position: relative; display: flex; flex: 1; min-width: 0; min-height: 0; overflow: hidden; }
.wl-se .wl-se-ink { position: absolute; inset: 0; margin: 0; padding: 14px 16px; overflow: clip; border: 0; border-radius: 0; background: none; color: var(--wl-text); font: 12.5px/1.75 var(--wl-font-mono); tab-size: 2; white-space: pre; pointer-events: none; }
.wl-se .wl-se-ink > code { display: block; margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; white-space: inherit; }
.wl-se[data-view="code"] .wl-se-ink { padding: 16px 18px; font-size: 13px; line-height: 1.75; }
.wl-se textarea.wl-se-editor { position: relative; color: transparent; -webkit-text-fill-color: transparent; }
.wl-se textarea.wl-se-editor::selection { background: color-mix(in srgb, var(--wl-accent) 32%, transparent); }
.wl-ink-k { color: var(--wl-ink-k); }
.wl-ink-s { color: var(--wl-ink-s); }
.wl-ink-n { color: var(--wl-ink-n); }
.wl-ink-f { color: var(--wl-ink-f); }
.wl-ink-p { color: var(--wl-ink-p); }
.wl-ink-o { color: var(--wl-ink-o); }
.wl-ink-d { color: var(--wl-text-3); }
.wl-ink-c { color: var(--wl-text-3); font-style: italic; }

/* Code stands still like an editor: the page doesn't scroll, the code fills the space and scrolls in itself,
   the log keeps the bottom with its own scroll, and Try it stays on the right (scrolling in itself when long). */
.wl-se[data-view="code"] .wl-se-page { display: flex; overflow: hidden; }
.wl-se[data-view="code"] .wl-se-cols { flex: 1; min-width: 0; min-height: 0; box-sizing: border-box; grid-template-columns: minmax(0, 1fr) 340px; grid-template-rows: minmax(0, 1fr); gap: 28px; max-width: 1480px; margin: 0 auto; padding: 20px 28px 24px; }
.wl-se[data-view="code"] .wl-se-main { display: flex; flex-direction: column; min-height: 0; }
.wl-se[data-view="code"] .wl-se-main > * { flex: none; }
.wl-se[data-view="code"] .wl-se-main > .wl-se-code { flex: 1 1 0; height: auto; min-height: 140px; }
.wl-se[data-view="code"] .wl-se-main > .wl-se-test { flex: 0 1 clamp(170px, 30%, 280px); height: auto; min-height: 120px; margin-top: 12px; }
.wl-se[data-view="code"] .wl-se-side { position: static; align-self: stretch; align-content: start; min-height: 0; overflow: auto; }

/* Narrower: Try it under the column. On a phone: smaller title, and each row's label over its value. */
@container (max-width: 960px) {
  .wl-se-cols, .wl-se[data-view="code"] .wl-se-cols { grid-template-columns: minmax(0, 680px); gap: 32px; padding: 28px 24px 80px; }
  .wl-se-side { position: static; }
  /* Too narrow to stand still: Code scrolls as a page again, the code and the log at set heights. */
  .wl-se[data-view="code"] .wl-se-page { display: block; overflow: auto; }
  .wl-se[data-view="code"] .wl-se-cols { grid-template-rows: none; max-width: none; }
  .wl-se[data-view="code"] .wl-se-main > .wl-se-code { flex: none; height: 420px; }
  .wl-se[data-view="code"] .wl-se-main > .wl-se-test { flex: none; height: 260px; }
  .wl-se[data-view="code"] .wl-se-side { overflow: visible; }
}
@container (max-width: 600px) {
  .wl-se-bar { gap: 6px; padding: 8px 10px 8px 14px; }
  .wl-se .wl-se-crumb > span:not(.wt-glyph), .wl-se-sep, .wl-se-state > span { display: none; }
  .wl-se .wl-se-view > span:not(.wt-glyph), .wl-se .wl-se-save > span:not(.wt-glyph) { display: none; }
  .wl-se .wl-se-btn { padding: 0 12px; }
  .wl-se-crumbs { flex: 1 1 auto; }
  .wl-se-crumbs b { flex: 0 1 auto; min-width: 3em; }
  .wl-se-cols, .wl-se[data-view="code"] .wl-se-cols { padding: 20px 16px 72px; }
  .wl-se .wl-ss-head .wl-ss-name { font-size: 28px; }
  .wl-se .wl-ss-head textarea.wl-ss-said { font-size: 15px; }
  .wl-ss-row { grid-template-columns: minmax(0, 1fr); gap: 4px; padding: 10px 0; }
  .wl-ss-row-k { font-size: 12.5px; }
  .wl-se .wl-ss-step { grid-template-columns: 24px minmax(0, 1fr) 28px; gap: 10px; }
  .wl-se .wl-ss-res { grid-column: 2; grid-row: 2; justify-self: start; }
  .wl-se .wl-ss-more { grid-column: 3; grid-row: 1; }
  .wl-se .wl-ss-row-v .wl-ss-step { grid-template-columns: minmax(0, 1fr) 28px; }
  .wl-se .wl-ss-row-v .wl-ss-res { grid-column: 1; }
  .wl-se .wl-ss-row-v .wl-ss-more { grid-column: 2; }
  .wl-ss-look { grid-template-columns: 48px minmax(0, 1fr) 28px; }
  .wl-ss-look .wl-ss-res { grid-column: 2; grid-row: 2; justify-self: start; }
  .wl-se .wl-ss-look-tile { width: 48px; height: 48px; }
  .wl-se[data-view="code"] .wl-se-main > .wl-se-code { height: 360px; }
}
.wl-se .wl-ss-step > .wl-ss-more, .wl-se .wl-ss-look > .wl-ss-more { grid-column: 4; }
.wl-se .wl-ss-row-v .wl-ss-step > .wl-ss-more { grid-column: 3; }
@container (max-width: 600px) { .wl-se .wl-ss-step > .wl-ss-more { grid-column: 3; } .wl-se .wl-ss-row-v .wl-ss-step > .wl-ss-more { grid-column: 2; } .wl-se .wl-ss-look > .wl-ss-more { grid-column: 3; grid-row: 1; } }

/* A type's scripts as a short list (D-162): each row opens the script's own page; one not saved yet has a
   remove beside it. */
.wt-sc-row.is-link { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.wt-sc-row.is-link > .wt-sc-head { grid-column: 1 / -1; }
.wt-sc-row.is-link:has(> .wt-sc-remove) > .wt-sc-head { grid-column: 1; }
.wt-sc-row.is-link:hover { box-shadow: inset 0 0 0 1px var(--wl-line-strong); }
.wt-surface .wt-sc-row.is-link > .wt-sc-remove { margin-right: 8px; color: var(--wl-text-3); }

/* Play → Numbers (D-160): the type's numbers that change in play, each with the scripts that change it. */
.wt-num { display: grid; gap: 6px; }
.wt-num-row { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; align-items: start; padding: 10px 12px; border-radius: var(--r-md); background: var(--wl-inset); box-shadow: inset 0 0 0 1px var(--wl-line); }
.wt-num-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--r-md); background: var(--wl-raised); color: var(--wl-text-2); }
.wt-ws .wt-num-icon svg { width: 16px; height: 16px; }
.wt-num-words { display: grid; gap: 6px; min-width: 0; padding-top: 1px; }
.wt-num-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.wt-num-top b { font-size: 13.5px; font-weight: 600; }
.wt-num-top small { color: var(--wl-text-3); font-size: 12px; }
.wt-num-tag { padding: 1px 8px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--wl-danger) 14%, transparent); color: color-mix(in srgb, var(--wl-danger) 80%, var(--wl-text)); font-size: 11.5px; font-weight: 600; }
.wt-num-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.wt-num-none { color: var(--wl-text-3); font-size: 12px; }
.wt-ws .wt-num .wt-num-chip { display: inline-flex; align-items: center; gap: 5px; width: auto; height: 26px; margin: 0; padding: 0 10px 0 8px; border: 1px solid var(--wl-line); border-radius: var(--r-pill); background: var(--wl-surface); box-shadow: none; color: var(--wl-text); font-size: 12px; font-weight: 600; cursor: pointer; }
.wt-ws .wt-num .wt-num-chip:hover { border-color: var(--wl-line-strong); background: var(--wl-raised); }
.wt-ws .wt-num-chip .wt-glyph { flex: none; width: 13px; height: 13px; color: var(--wl-text-3); }
