/* Gravity UI: the design foundation (2026-11-12, issue #98).
 *
 * Shared page and control styles. surface-theme.css owns the default tokens.
 * workspace-appearance.js applies saved workspace values to the root and shell.
 */

/* The staff shell carries the product identity. Customer portals have their own themes. */
#appShell .rail {
  --ground: var(--sheet);
  --gd-hover: color-mix(in srgb, var(--sign) 8%, var(--sheet));
  background: var(--ground);
  color: var(--ink);
}

#appShell .rail[data-workspace-sidebar] {
  background: var(--workspace-sidebar);
  --ground: var(--workspace-sidebar);
  --sheet: color-mix(in srgb, var(--workspace-sidebar) 94%, var(--workspace-sidebar-ink));
  --rule: color-mix(in srgb, var(--workspace-sidebar) 72%, var(--workspace-sidebar-ink));
  --rule-soft: color-mix(in srgb, var(--workspace-sidebar) 85%, var(--workspace-sidebar-ink));
  --gd-hover: var(--sheet-2);
  --ink: var(--workspace-sidebar-ink);
  --ink-2: var(--workspace-sidebar-ink);
  --ink-3: var(--workspace-sidebar-ink);
  --sheet-2: color-mix(in srgb, var(--workspace-sidebar) 85%, var(--workspace-sidebar-ink));
}
#appShell .rail[data-workspace-sidebar] :is(.brand,a,.who b,.who span,.ws,.ws strong,.nav-section,.theme,.signout) {
  color: var(--workspace-sidebar-ink);
}

@media (min-width: 901px) {
  #appShell .rail:not(.rail-expanded) .brand #workspaceLogo { display: none; }
}
#appShell .rail .brand .qdini-staff-mark { flex: 0 0 30px; object-fit: contain; }
#appShell .rail .brand span { overflow: hidden; text-overflow: ellipsis; }
#appShell .rail a[data-view][aria-current=page] svg { color: var(--sign); }
#loginView { background: radial-gradient(ellipse at top, var(--sign-wash), transparent 65%), var(--ground); }
#loginView .login-brand { gap: 12px; color: var(--ink); font-size: 26px; letter-spacing: -.045em; }
#loginView .login-card { border-top: 3px solid var(--brand-champagne); background: var(--sheet); }
#loginView .login-submit { background: var(--sign); color: var(--sign-ink); }
#loginView .login-submit:hover { background: color-mix(in srgb,var(--sign) 90%,#000); }

#appShell .rail[data-workspace-sidebar] a[data-view][aria-current=page] {
  background: var(--sheet-2);
  color: var(--workspace-sidebar-ink);
}
#appShell .rail[data-workspace-sidebar] a[data-view][aria-current=page] svg { color: currentColor; }
#appShell .gx .vpane { background: var(--sheet-2); }
#appShell .gx .vpane .vrow:hover { background: var(--gd-hover); }
#appShell .gx .vpane .vrow[aria-current=true] { color: var(--sign); background: var(--sign-wash); }

/* ---------- Type ---------- */
body,.gx,#appShell{font-family:var(--ui);-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
#appShell .top h1,.gx .login-card h1{letter-spacing:-.02em}
::selection{background:color-mix(in srgb,var(--sign) 26%,transparent)}

/* ---------- Focus: one visible ring everywhere ---------- */
#appShell :is(a,button,[tabindex],summary):focus-visible,.gd-cmdk :is(button,input):focus-visible{outline:2px solid var(--sign);outline-offset:2px}

/* ---------- Buttons ---------- */
#appShell :is(.btn,.cc-button){border-radius:var(--control-radius);min-height:36px;font-size:13px;font-weight:600;letter-spacing:-.005em;transition:background-color var(--gd-fast) var(--gd-ease),border-color var(--gd-fast) var(--gd-ease),box-shadow var(--gd-fast) var(--gd-ease),transform 80ms var(--gd-ease)}
#appShell :is(.btn,.cc-button):hover:not(:disabled){box-shadow:var(--gd-shadow-1)}
#appShell :is(.btn,.cc-button):active:not(:disabled){transform:translateY(1px);box-shadow:none}
#appShell :is(.btn.sign,.cc-primary){background:var(--sign);color:var(--sign-ink);border-color:transparent;box-shadow:inset 0 1px 0 rgba(255,255,255,.16),0 1px 2px color-mix(in srgb,var(--sign) 38%,transparent)}
#appShell :is(.btn.sign,.cc-primary):hover:not(:disabled){background:color-mix(in srgb,var(--sign) 88%,#000);box-shadow:inset 0 1px 0 rgba(255,255,255,.16),0 3px 10px color-mix(in srgb,var(--sign) 34%,transparent)}
#appShell :is(.btn,.cc-button):disabled{opacity:.55;cursor:not-allowed}
.gx .login-submit{border-radius:var(--control-radius);transition:background-color var(--gd-fast) var(--gd-ease),transform 80ms var(--gd-ease)}
.gx .login-card{border-radius:var(--gd-radius-l);box-shadow:var(--gd-shadow-2)}
.gx .login-card input{border-radius:var(--control-radius)}
.gx .login-card a,.gx .login-card a:visited{color:var(--sign);text-underline-offset:3px}

/* ---------- Menus, toasts, dialogs ---------- */
.gx .menu{border-radius:12px;padding:6px;border-color:var(--rule-soft);box-shadow:var(--gd-shadow-3);transform-origin:top left;animation:gd-pop var(--gd-med) var(--gd-ease)}
.gx .menu button{border-radius:8px;transition:background-color var(--gd-fast) var(--gd-ease)}
.gx .toast{border-radius:11px;padding:11px 16px;box-shadow:var(--gd-shadow-3);animation:gd-toast 240ms var(--gd-ease)}
#appShell dialog[open]{animation:gd-fade var(--gd-med) var(--gd-ease)}
#appShell dialog::backdrop{background:var(--gd-scrim);backdrop-filter:blur(2px);animation:gd-fade var(--gd-med) var(--gd-ease)}

/* ---------- Views fade in when you switch ---------- */
#appShell .main>.gx>.desk,#appShell .main>section:not([hidden]),#appShell .main>.gx>section:not([hidden]){animation:gd-fade 180ms var(--gd-ease)}

/* ---------- Sidebar: labelled, calm, obviously navigation ---------- */
@media(min-width:901px){
  #appShell.app.gxroot{--rail-collapsed:64px;--rail-expanded:236px}
  #appShell .rail{background:var(--ground);border-right:1px solid var(--rule-soft);padding:18px 10px 12px;transition:width var(--gd-med) var(--gd-ease),box-shadow var(--gd-med) var(--gd-ease)}
  #appShell .rail.rail-expanded{box-shadow:var(--gd-shadow-2)}
  #appShell.rail-pinned .rail{box-shadow:none}
  #appShell .rail .brand{margin-bottom:14px;font-weight:650;letter-spacing:-.02em}
  #appShell .rail a[data-view]{min-height:38px;padding:8px 12px;margin:1px 0;border-radius:9px;font-size:13.5px;font-weight:500;color:var(--ink-2);gap:12px;transition:background-color var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease),box-shadow var(--gd-fast) var(--gd-ease)}
  #appShell .rail a[data-view]:hover{background:var(--gd-hover);color:var(--ink)}
  #appShell .rail a[data-view][aria-current=page]{background:var(--sign-wash);color:var(--sign);font-weight:600;box-shadow:none}
  #appShell .rail a[data-view][aria-current=page] svg{color:var(--sign)}
  #appShell .rail .me{border-top-color:var(--rule-soft)}
  #appShell .rail .me .who:hover{background:var(--gd-hover)}
  /* The jump button: full row when the rail shows labels, an icon when not. */
  #appShell .rail .gd-jump{display:flex;align-items:center;gap:10px;width:100%;box-sizing:border-box;min-height:36px;margin:0 0 12px;padding:0 10px;border:1px solid var(--rule);border-radius:9px;background:var(--sheet);color:var(--ink-3);font:500 13px var(--ui);cursor:pointer;white-space:nowrap;overflow:hidden;transition:border-color var(--gd-fast) var(--gd-ease),box-shadow var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease)}
  #appShell .rail .gd-jump:hover{border-color:var(--ink-4);color:var(--ink);box-shadow:var(--gd-shadow-1)}
  #appShell .rail .gd-jump svg{width:15px;min-width:15px;height:15px}
  #appShell .rail .gd-jump span{flex:1;text-align:left}
  #appShell .rail .gd-jump kbd{font:500 11px var(--ui);padding:1px 5px;border:1px solid var(--rule);border-radius:5px;color:var(--ink-3);background:var(--sheet-2)}
  #appShell .rail:not(.rail-expanded) .gd-jump{justify-content:center;padding:0}
  #appShell .rail:not(.rail-expanded) .gd-jump :is(span,kbd){display:none}
}
@media(max-width:900px){
  #appShell :is(.btn,.cc-button){min-height:44px}
  #appShell .rail .gd-jump{display:none}
  /* Phone ticket list: the search box stays inside the screen, and Preview
     sits in the card's corner instead of taking a row of its own. */
  /* AI agent page: its columns may shrink to the screen instead of pushing it sideways. */
  #appShell .agx .apb,#appShell .agx .apb .path{grid-template-columns:minmax(0,1fr);min-width:0}
  /* The details view's Close button is text on phones: let it size to its label. */
  #appShell .gx .side-h .pane-btn{width:auto;white-space:nowrap;padding-left:8px;padding-right:8px}
  #appShell .gx .mobile-queue-search{box-sizing:border-box;width:auto;max-width:calc(100% - 28px)}
  #appShell .gx .ticket-table td:nth-child(2){position:relative;padding-right:84px}
  #appShell .gx .ticket-table .ticket-peek-trigger{position:absolute;top:0;right:0;margin:0;min-height:36px;padding:6px 12px}
}

/* ---------- Tickets: tab strip ---------- */
/* An open ticket's tab reads "1187 Subject…" on one line with a real ellipsis. */
#appShell .gx .tabs .tab.cv .tl{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:13px;line-height:20px}
#appShell .gx .tabs .tab.cv .tid{display:inline;width:auto;margin-right:6px;font:500 12px var(--code);color:var(--ink-3)}
#appShell .gx .tabs .tab{border-radius:8px 8px 0 0;transition:background-color var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease)}

/* ---------- Tickets: queues panel ---------- */
@media(min-width:901px){
  /* Wide enough to read queue names by default, and yours to resize. */
  #appShell .gx .split{position:relative}
  #appShell .gx .split:not(.v-off){grid-template-columns:var(--gd-queues-w,264px) minmax(0,1fr)}
  #appShell .gx .split.is-resizing{transition:none;user-select:none;cursor:col-resize}
  #appShell .gx .split .gd-resize{position:absolute;z-index:5;top:0;bottom:0;left:calc(var(--gd-queues-w,264px) - 4px);width:8px;cursor:col-resize;touch-action:none}
  #appShell .gx .split .gd-resize::after{content:"";position:absolute;top:0;bottom:0;left:3px;width:2px;border-radius:2px;background:transparent;transition:background-color var(--gd-fast) var(--gd-ease)}
  #appShell .gx .split .gd-resize:is(:hover,:focus-visible,.is-dragging)::after{background:var(--sign)}
  #appShell .gx .split .gd-resize:focus-visible{outline:none}
  #appShell .gx .split.v-off .gd-resize{display:none}
}
@media(max-width:900px){#appShell .gx .split .gd-resize{display:none}}
/* Rows: name first, then one quiet total. Overdue is the only loud number,
   and only when there is one. */
#appShell .gx .vpane{padding:8px 10px 20px}
#appShell .gx .vpane .vrow{grid-template-columns:18px minmax(0,1fr) auto auto;gap:10px;min-height:36px;padding:7px 10px;margin:1px 0;border-radius:8px;font-size:13.5px;transition:background-color var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease)}
#appShell .gx .vpane .vrow .cnt{min-width:0;padding:0;background:transparent;color:var(--ink-3);font:500 12.5px var(--ui);font-variant-numeric:tabular-nums;text-align:right}
#appShell .gx .vpane .vrow .cnt.p{background:transparent;color:var(--pend);font-weight:600}
#appShell .gx .vpane .vrow .od{padding:1px 7px;border-radius:999px;background:color-mix(in srgb,var(--a1) 12%,var(--sheet));color:var(--a1);font:600 11.5px var(--ui);font-variant-numeric:tabular-nums}
#appShell .gx .vpane .vrow .od::after{content:" late";font-weight:500}
#appShell .gx .vpane .vrow[aria-current=true] .cnt{color:inherit}
#appShell .gx .vpane .sub{padding:20px 10px 6px;font-size:11px;letter-spacing:.04em;text-transform:uppercase;color:var(--ink-3)}
#appShell .gx .vpane .note{padding:4px 10px;color:var(--ink-3);font-size:12.5px;line-height:1.5}

/* ---------- Tickets: list ---------- */
#appShell .gx .ticket-table tbody tr{transition:background-color var(--gd-fast) var(--gd-ease)}
#appShell .gx .ticket-table .ticket-subject{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
@media(min-width:901px) and (hover:hover){
  /* Preview waits at the end of the subject cell until the row is pointed at
     or focused, so rows stay one glance tall. */
  #appShell .gx .ticket-table td:nth-child(2){position:relative;padding-right:92px}
  #appShell .gx .ticket-table .ticket-peek-trigger{position:absolute;right:10px;top:50%;margin:0;transform:translateY(-50%);opacity:0;pointer-events:none;transition:opacity var(--gd-fast) var(--gd-ease)}
  #appShell .gx .ticket-table tr:is(:hover,:focus-within) .ticket-peek-trigger,#appShell .gx .ticket-table .ticket-peek-trigger:is(:focus-visible,[aria-expanded=true]){opacity:1;pointer-events:auto}
}

/* ---------- Tickets: conversation ---------- */
/* Requester and organization are chips, not underlined links. */
#appShell .gx .req :is(.rq,.orgl){text-decoration:none;border-radius:8px;transition:border-color var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease)}
#appShell .gx .req :is(.rq,.orgl):hover{text-decoration:none;border-color:var(--sign);color:var(--sign)}
/* Details pane header: the tabs scroll inside their own space and can never
   slide under the collapse button. */
#appShell .gx .side-h{gap:2px;padding-left:8px;padding-right:6px}
#appShell .gx .side-h .dtabs{flex:1 1 auto;min-width:0;overflow-x:auto;scrollbar-width:none}
#appShell .gx .side-h .dtabs::-webkit-scrollbar{display:none}
#appShell .gx .side-h .dtabs{gap:0}
#appShell .gx .side-h .dtabs button{flex:0 0 auto;padding:0 7px;font-size:12.5px}
#appShell .gx .side-h .pane-btn{flex:0 0 auto;min-width:30px;margin-left:2px}
/* Notices at the top of the reply box get the same inset as everything else in it. */
#appShell .gx .composer>p.note{margin:0;padding:10px 14px;display:flex;flex-wrap:wrap;align-items:center;gap:8px;font-size:12.5px;color:var(--ink-2);border-bottom:1px solid var(--rule-soft)}
/* Internal note: a soft amber wash from the theme's own tokens (the old rule
   hard-coded a light cream, which glared in dark and hid the white text). */
#appShell #dDesk .composer.inote .editor.ticket-rich-editor,#appShell #dDesk .composer.inote .ticket-message-canvas,#appShell .nt-message.is-internal .ticket-message-canvas{background:var(--pend-wash);border-color:color-mix(in srgb,var(--pend) 38%,var(--rule));color:var(--ink)}
#appShell #dDesk .composer.inote .ticket-message-canvas [contenteditable]{color:var(--ink);caret-color:var(--ink)}
@media(min-width:901px){
  /* The conversation gets the room; the reply box is compact until you are
     writing in it. */
  #appShell #dDesk .dock .composer .editor.ticket-rich-editor{min-height:118px;transition:min-height var(--gd-med) var(--gd-ease)}
  #appShell #dDesk .dock .composer .ticket-message-canvas{min-height:64px}
  /* Keyed to the editor itself, not the whole reply box: the dock is anchored
     to the bottom, so growing only moves what is above the editor, and the
     buttons you are reaching for (tabs, Add CC, Send) never jump mid-click. */
  #appShell #dDesk .dock .composer .editor.ticket-rich-editor:focus-within{min-height:220px}
  #appShell #dDesk .dock .composer .editor:focus-within .ticket-message-canvas{min-height:160px}
  #appShell #dDesk .dock .composer .editor:not(:focus-within) .ticket-formatting{display:none}
  #appShell #dDesk .dock .composer .editor:not(:focus-within) .ticket-message-canvas{min-height:96px}
  /* Room for all three details tabs beside the collapse button. */
  #appShell .gx .panes:not(.s-off){--sw:348px}
  #appShell .gx .panes:not(.s-off) .side{width:348px}
}

/* ---------- Control Center: key figures as tiles ---------- */
/* Neutral by default. Color appears only on a figure that needs a look. */
#appShell .cc-kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(132px,1fr));gap:10px;padding:0;border:0;background:transparent}
#appShell .cc-kpi{min-width:0;padding:14px 16px;border:1px solid var(--rule-soft);border-left:1px solid var(--rule-soft);border-radius:var(--gd-radius-l);background:var(--sheet);box-shadow:var(--gd-shadow-1)}
#appShell .cc-kpi b{font-size:24px;letter-spacing:-.02em}
#appShell .cc-kpi span{font-size:12px;color:var(--ink-3)}
#appShell .cc-kpi[data-tone=alert]{background:color-mix(in srgb,var(--a1) 9%,var(--sheet));border-color:color-mix(in srgb,var(--a1) 28%,var(--sheet))}
#appShell .cc-kpi[data-tone=alert] b{color:var(--a1)}
#appShell .cc-kpi[data-tone=warn]{background:var(--pend-wash);border-color:color-mix(in srgb,var(--pend) 30%,var(--sheet))}
#appShell .cc-kpi[data-tone=warn] b{color:var(--pend)}
#appShell .cc-kpi[data-tone=good]{background:color-mix(in srgb,var(--ok) 8%,var(--sheet));border-color:color-mix(in srgb,var(--ok) 26%,var(--sheet))}
#appShell .cc-kpi[data-tone=good] b{color:var(--ok)}

/* ---------- Dashboards: tile actions ---------- */
/* Clicking a chart already drills in, so Drill down and Logic are quiet text
   actions instead of two full buttons under every tile. They brighten when
   the tile is pointed at or focused; on touch they are always readable. */
#appShell .dsh .metric-tile-actions{display:flex;gap:2px;margin-top:6px;padding-top:6px;border-top:1px solid var(--rule-soft)}
#appShell .dsh .metric-tile-actions .btn{min-height:28px;padding:2px 8px;border:0;background:transparent;box-shadow:none;color:var(--ink-3);font-size:12px;font-weight:500;border-radius:6px}
#appShell .dsh .metric-tile-actions .btn:hover{background:var(--gd-hover);color:var(--sign);box-shadow:none}
@media(hover:hover) and (min-width:901px){
  #appShell .dsh .tile .metric-tile-actions{opacity:.55;transition:opacity var(--gd-fast) var(--gd-ease)}
  #appShell .dsh .tile:is(:hover,:focus-within) .metric-tile-actions{opacity:1}
}
@media(max-width:900px){#appShell .dsh .metric-tile-actions .btn{min-height:40px}}

/* ---------- Live chat inside Tickets (issue #104) ---------- */
#appShell .gx .vpane .gd-chat-group{margin-bottom:4px}
#appShell .gx .vpane .gd-chat-row{grid-template-columns:18px minmax(0,1fr) auto auto;width:100%}
#appShell .gd-chat-dot{justify-self:center;width:8px;height:8px;border-radius:50%;background:var(--ink-4)}
#appShell .gd-chat-dot.is-live{background:var(--ok);box-shadow:0 0 0 0 color-mix(in srgb,var(--ok) 60%,transparent);animation:gd-pulse 1.8s var(--gd-ease) infinite}
@keyframes gd-pulse{to{box-shadow:0 0 0 7px transparent}}
/* The dock is a third column of the Tickets split: chats on one side, the
   ticket or chat you opened on the other, nothing to switch between. */
#appShell .gd-chat-dock{display:flex;flex-direction:column;min-width:0;min-height:0;background:var(--sheet);border-left:1px solid var(--rule);animation:gd-fade var(--gd-med) var(--gd-ease)}
#appShell .gd-chat-dock[hidden]{display:none}
@media(min-width:901px){
  #appShell .gx .split.gd-chat-open:not(.v-off){grid-template-columns:var(--gd-queues-w,264px) minmax(0,1fr) 340px}
  #appShell .gx .split.gd-chat-open.v-off{grid-template-columns:44px minmax(0,1fr) 340px}
}
@media(max-width:900px){#appShell .gd-chat-dock{position:fixed;inset:54px 0 0;z-index:70;border-left:0}}
#appShell .gd-chat-head{display:flex;align-items:center;gap:8px;padding:12px 12px 10px 16px;border-bottom:1px solid var(--rule-soft)}
#appShell .gd-chat-head h2{flex:1;margin:0;font:650 15px var(--ui);letter-spacing:-.01em;color:var(--ink)}
#appShell .gd-chat-head .pane-btn{display:grid;font-size:20px;line-height:1}
#appShell .gd-chat-tabs{display:flex;gap:4px;padding:10px 12px;border-bottom:1px solid var(--rule-soft)}
#appShell .gd-chat-tabs button{flex:1;min-height:32px;padding:0 8px;border:0;border-radius:8px;background:transparent;color:var(--ink-3);font:600 12.5px var(--ui);cursor:pointer;transition:background-color var(--gd-fast) var(--gd-ease),color var(--gd-fast) var(--gd-ease)}
#appShell .gd-chat-tabs button:hover{background:var(--gd-hover);color:var(--ink)}
#appShell .gd-chat-tabs button[aria-pressed=true]{background:var(--sign-wash);color:var(--sign)}
#appShell .gd-chat-list{flex:1;min-height:0;overflow-y:auto;padding:8px}
#appShell .gd-chat-item{display:flex;flex-direction:column;gap:3px;width:100%;padding:11px 12px;margin:2px 0;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--ink);font:400 13px var(--ui);text-align:left;cursor:pointer;transition:background-color var(--gd-fast) var(--gd-ease),border-color var(--gd-fast) var(--gd-ease)}
#appShell .gd-chat-item:hover{background:var(--sheet-2)}
#appShell .gd-chat-item[aria-current=true]{background:var(--sign-wash);border-color:color-mix(in srgb,var(--sign) 30%,transparent)}
#appShell .gd-chat-item-top{display:flex;align-items:baseline;justify-content:space-between;gap:8px}
#appShell .gd-chat-item-top b{font-weight:600;font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#appShell .gd-chat-state{flex:none;font-size:11.5px;color:var(--ink-3)}
#appShell .gd-chat-state.is-waiting{color:var(--a2);font-weight:600}
#appShell .gd-chat-subject{color:var(--ink-2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#appShell .gd-chat-meta{font-size:12px;color:var(--ink-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#appShell .gd-chat-live{font-size:12px;font-weight:600;color:var(--ok)}
#appShell :is(.gd-chat-empty,.gd-chat-error){margin:0;padding:22px 14px;color:var(--ink-3);font:400 13px/1.5 var(--ui);text-align:center}
#appShell .gd-chat-error{color:var(--a1)}
#appShell .gd-chat-strip{display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;flex:none;padding:8px 28px;background:var(--sheet-2);border-bottom:1px solid var(--rule-soft);font:400 12.5px var(--ui);color:var(--ink-2)}
#appShell .gd-chat-badge{padding:2px 9px;border-radius:999px;background:color-mix(in srgb,var(--ok) 14%,var(--sheet));color:var(--ok);font-weight:600;font-size:11.5px}
#appShell .gd-chat-mode{color:var(--ink-3)}
#appShell .gd-chat-strip .gd-chat-live{margin-left:auto}
#appShell .gd-chat-strip :is(.gd-chat-mode,.gd-chat-live):empty{display:none}
#appShell .chat-conversations :is(.chat-context,.chat-live){display:block;font-size:12px;color:var(--ink-3)}
#appShell .chat-conversations .chat-live{color:var(--ok);font-weight:600}

/* ---------- Dashboards: staffing estimate (issue #105) ---------- */
#appShell .staffing-estimate{margin:16px 0 8px;padding:22px 24px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-l);background:var(--sheet);box-shadow:var(--gd-shadow-1)}
#appShell .staffing-estimate>header h3{margin:0 0 4px;font:650 17px var(--ui);letter-spacing:-.01em;color:var(--ink)}
#appShell .staffing-estimate>header p{margin:0 0 18px;max-width:720px;color:var(--ink-3);font:400 13px/1.5 var(--ui)}
#appShell .staffing-grid{display:grid;grid-template-columns:minmax(260px,360px) minmax(0,1fr);gap:28px;align-items:start}
#appShell .staffing-form{display:grid;gap:12px}
#appShell .staffing-form label{display:grid;gap:5px;font:600 12.5px var(--ui);color:var(--ink-2)}
#appShell .staffing-form input{min-height:38px;padding:0 12px;border:1px solid var(--rule);border-radius:var(--control-radius);background:var(--sheet);color:var(--ink);font:500 14px var(--ui);font-variant-numeric:tabular-nums}
#appShell .staffing-form small{font:400 11.5px/1.4 var(--ui);color:var(--ink-3)}
#appShell .staffing-sides{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:14px}
#appShell .staffing-side{padding:18px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-m);background:var(--sheet-2)}
#appShell .staffing-side h4{margin:0;font:600 11px var(--ui);letter-spacing:.05em;text-transform:uppercase;color:var(--ink-3)}
#appShell .staffing-big{margin:6px 0 8px;font:700 30px/1.1 var(--ui);letter-spacing:-.02em;color:var(--ink)}
#appShell .staffing-big small{font:500 14px var(--ui);color:var(--ink-3)}
#appShell .staffing-tag{display:inline-block;padding:3px 10px;border-radius:999px;font:600 12px var(--ui);background:var(--rule-soft);color:var(--ink-2)}
#appShell .staffing-side[data-pressure=over] .staffing-tag{background:color-mix(in srgb,var(--a1) 13%,var(--sheet));color:var(--a1)}
#appShell .staffing-side[data-pressure=stretched] .staffing-tag{background:var(--pend-wash);color:var(--pend)}
#appShell .staffing-side[data-pressure=steady] .staffing-tag{background:color-mix(in srgb,var(--ok) 12%,var(--sheet));color:var(--ok)}
#appShell .staffing-side>p:not(.staffing-big){margin:10px 0 12px;color:var(--ink-2);font:400 13px/1.5 var(--ui)}
#appShell .staffing-side dl{margin:0;display:grid;gap:6px}
#appShell .staffing-side dl>div{display:flex;justify-content:space-between;gap:12px;font:400 13px var(--ui)}
#appShell .staffing-side dt{color:var(--ink-3)}
#appShell .staffing-side dd{margin:0;font-weight:600;font-variant-numeric:tabular-nums;color:var(--ink)}
#appShell .staffing-delta{margin:14px 0 0;color:var(--ink-2);font:400 14px var(--ui)}
#appShell .staffing-wait{margin:0;padding:28px 18px;border:1px dashed var(--rule);border-radius:var(--gd-radius-m);color:var(--ink-3);font:400 13px var(--ui);text-align:center}
@media(max-width:900px){#appShell .staffing-grid{grid-template-columns:1fr;gap:18px}#appShell .staffing-estimate{padding:16px}#appShell .staffing-form input{min-height:44px;font-size:16px}}
@media print{#appShell .staffing-form small{display:none}}

/* ---------- Command palette (Ctrl/Cmd+K) ---------- */
.gd-cmdk{position:fixed;inset:0;z-index:200;display:flex;justify-content:center;align-items:flex-start;padding:14vh 16px 16px;background:var(--gd-scrim);backdrop-filter:blur(3px);font-family:var(--ui);animation:gd-fade 140ms var(--gd-ease)}
.gd-cmdk[hidden]{display:none}
.gd-cmdk-panel{width:min(600px,100%);max-height:min(460px,70vh);display:flex;flex-direction:column;background:var(--sheet);color:var(--ink);border:1px solid var(--rule-soft);border-radius:16px;box-shadow:var(--gd-shadow-3);overflow:hidden;animation:gd-pop var(--gd-med) var(--gd-ease)}
.gd-cmdk-input{box-sizing:border-box;width:100%;height:54px;padding:0 20px;border:0;border-bottom:1px solid var(--rule-soft);background:transparent;color:var(--ink);font:500 16px var(--ui)}
.gd-cmdk .gd-cmdk-input:focus-visible{outline:none}
.gd-cmdk-input::placeholder{color:var(--ink-3)}
.gd-cmdk-list{margin:0;padding:8px;list-style:none;overflow-y:auto}
.gd-cmdk-group{padding:8px 12px 4px;font:600 11px var(--ui);letter-spacing:.04em;text-transform:uppercase;color:var(--ink-3)}
.gd-cmdk-item{display:flex;align-items:center;gap:10px;min-height:42px;padding:0 12px;border-radius:9px;color:var(--ink);font:500 14px var(--ui);cursor:pointer}
.gd-cmdk-item[aria-selected=true]{background:var(--sign-wash);color:var(--ink)}
.gd-cmdk-item small{margin-left:auto;color:var(--ink-3);font:400 12px var(--ui)}
.gd-cmdk-empty{padding:22px 12px;color:var(--ink-3);font:400 14px var(--ui);text-align:center}
.gd-cmdk-foot{display:flex;gap:16px;padding:9px 16px;border-top:1px solid var(--rule-soft);color:var(--ink-3);font:400 12px var(--ui)}
@media(max-width:600px){.gd-cmdk{padding-top:8vh}.gd-cmdk-foot{display:none}}

/* ---------- Motion ---------- */
@keyframes gd-fade{from{opacity:0}to{opacity:1}}
@keyframes gd-pop{from{opacity:0;transform:translateY(-4px) scale(.98)}to{opacity:1;transform:none}}
@keyframes gd-toast{from{opacity:0;transform:translate(-50%,8px)}to{opacity:1;transform:translate(-50%,0)}}
@media(prefers-reduced-motion:reduce){
  #appShell *,.gx *,.gd-cmdk,.gd-cmdk *{animation:none!important;transition:none!important}
}

/* ---------- Round 4 clean-up, 2026-11-12 ---------- */
/* One search field for every dialog and panel, whichever screen opens it. */
.fsearch{display:flex;align-items:center;gap:8px;min-height:36px;padding:0 11px;border:1px solid var(--rule);border-radius:var(--gd-radius-m,8px);background:var(--sheet);color:var(--ink-3)}
.fsearch:focus-within{border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 18%,transparent)}
.fsearch input,.fsearch input:focus,.fsearch input:focus-visible{flex:1;min-width:0;width:100%;border:0!important;outline:0!important;box-shadow:none!important;background:none;padding:0;font:inherit;font-size:13px;color:var(--ink)}
.fsearch svg.i{flex:none;width:15px;height:15px}
body label.fsearch{display:flex!important;flex-direction:row;align-items:center;margin:0}
.gx .queue-toolbar{flex-wrap:wrap;row-gap:10px}
.gx .queue-toolbar .queue-search{flex:1 1 220px;min-width:200px}

/* In-app question dialog (replaces the browser's own confirm box). */
dialog.gd-ask{width:min(440px,calc(100vw - 32px));padding:22px 24px 18px;border:1px solid var(--rule);border-radius:var(--gd-radius-l,12px);background:var(--sheet);color:var(--ink);font:14px/1.5 var(--ui);box-shadow:var(--gd-shadow-3,0 24px 60px #0003)}
dialog.gd-ask::backdrop{background:#0f172a66}
dialog.gd-ask h2{margin:0 0 6px;font-size:16px}
dialog.gd-ask p{margin:0 0 18px;color:var(--ink-2)}
.gd-ask-actions{display:flex;justify-content:flex-end;gap:8px}

/* Disclosures: no browser triangle; a chevron on the right that turns when open. */
#appShell details>summary{list-style:none;cursor:pointer}
#appShell details>summary::-webkit-details-marker{display:none}
#appShell details>summary:not(.btn):not(.pb)::after{content:"";display:inline-block;width:6px;height:6px;margin-left:8px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:translateY(-2px) rotate(45deg);transition:transform var(--gd-fast,.15s);opacity:.55}
#appShell details[open]>summary:not(.btn):not(.pb)::after{transform:translateY(1px) rotate(-135deg)}

/* Team coverage sits in the ticket stage, which has no page padding of its own. */
#dDesk .report-page{box-sizing:border-box;max-width:1180px;padding:26px 32px 48px}
#dDesk .report-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:18px}
#dDesk .report-heading h2{margin:2px 0 6px;font-size:22px;letter-spacing:-.01em}
#dDesk .report-heading p{margin:0;color:var(--ink-3);font-size:13px;max-width:70ch}
#dDesk .coverage-summary{margin:0 0 16px;padding:14px 16px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-l,12px);background:var(--sheet);color:var(--ink-3);font-size:13px}
#dDesk .coverage-summary b{margin-right:6px;font-size:22px;color:var(--ink)}
#dDesk .report-page .ticket-table{width:100%;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-l,12px);background:var(--sheet);border-collapse:separate;border-spacing:0;overflow:hidden}
#dDesk .report-page .ticket-table :is(th,td){padding:11px 16px;text-align:left}
#dDesk .report-page .ticket-table small{display:block;color:var(--ink-3)}

/* Dashboard list: each group reads as its own block. */
.dsh .dlist .dgrp{margin-top:18px;padding-top:14px;border-top:1px solid var(--rule-soft)}
.dsh .dlist .dgrp .sgh{padding:0 8px 8px;font-size:10.5px;font-weight:700;letter-spacing:.08em;color:var(--ink-3)}
.dsh .dlist .dgrp .di{padding-left:10px}

/* Playbooks and Knowledge: the Collections heading and its button share one tidy row. */
.kn .tree .thd{gap:10px;padding:2px 4px 10px 8px;margin-bottom:6px;border-bottom:1px solid var(--rule-soft)}
.kn .tree .thd .btn{flex:none;min-height:28px;padding:3px 9px;font-size:12px;box-shadow:none}
.kn .tree .thd .lbl{min-width:0;overflow:hidden;text-overflow:ellipsis}

/* Control Center figures that open the matching ticket list. */
#appShell button.cc-kpi{display:block;width:100%;text-align:left;font:inherit;color:inherit;cursor:pointer;transition:transform var(--gd-fast,.15s),box-shadow var(--gd-fast,.15s),border-color var(--gd-fast,.15s)}
#appShell button.cc-kpi b,#appShell button.cc-kpi span{display:block}
#appShell button.cc-kpi:hover{transform:translateY(-1px);box-shadow:var(--gd-shadow-2);border-color:color-mix(in srgb,var(--sign) 40%,var(--rule))}
#appShell button.cc-row-link{width:100%;border:0;border-bottom:1px dashed var(--rule);background:none;font:inherit;font-size:12px;color:inherit;cursor:pointer;text-align:left}
#appShell .cc-kpi{display:flex;flex-direction:column;gap:3px}
.gx .vpane .vrow.add span{white-space:nowrap}
.hc-editor .banner-options .setup-fields{margin:0}.hc-editor .help-announcement-editor .setup-box{margin:12px 0}
#appShell button.cc-row-link:hover{background:var(--sign-wash);color:var(--sign)}

/* Help Center studio. */
.hc-studio-layout{grid-template-columns:360px minmax(0,1fr)}
.hc-editor{max-height:calc(100vh - 150px)}
.hc-editor nav{display:flex;gap:2px;padding:6px 8px 0;border-bottom:1px solid var(--rule-soft)}
.hc-editor nav button{flex:1 1 auto;padding:10px 6px 11px;border-radius:0;border-bottom:2px solid transparent;font-size:12px;white-space:nowrap}
.hc-editor nav button:hover{background:none;color:var(--ink)}
.hc-editor nav [aria-pressed=true]{background:none;box-shadow:none;border-bottom-color:var(--sign);color:var(--sign);font-weight:600}
.hc-design-assistant{margin:14px 16px 0;padding:0;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2)}
.hc-design-assistant>summary{display:flex;align-items:center;justify-content:space-between;padding:10px 12px;font-size:12.5px;font-weight:600}
.hc-design-assistant[open]{padding-bottom:12px}
.hc-design-assistant>:not(summary){margin-left:12px;margin-right:12px}
.hc-editor #helpDraft{padding:18px 16px 22px}
.hc-editor .hc-sub{margin-top:22px;padding-top:18px;border-top:1px solid var(--rule-soft)}
.hc-editor .hc-sub h3{margin-top:0}
.hc-editor .banner-options .setup-fields{gap:0 10px;grid-template-columns:1fr 1fr}
.hc-editor .banner-options .setup-fields label:first-child{grid-column:1/-1}
.hc-editor .banner-options label{margin:0 0 12px}
.hc-editor .banner-format{display:flex;gap:6px;margin-bottom:8px}
.hc-editor .banner-link{margin:0 0 10px;padding:10px 12px;border:1px solid var(--rule);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2)}
.hc-editor .banner-link label{margin:0 0 8px}
.hc-editor .banner-link-actions{display:flex;gap:6px}
.hc-editor .banner-link-error{margin:8px 0 0;font-size:12px;color:var(--a1)}
.hc-editor .banner-editor{min-height:64px;padding:10px 12px;border:1px solid var(--rule);border-radius:var(--gd-radius-m,8px);background:var(--sheet);font-size:13px;line-height:1.5;margin-bottom:10px}
.hc-editor .banner-editor:focus{outline:0;border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 18%,transparent)}
.hc-save-bar{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:12px 16px}
.hc-save-bar #helpActionStatus{flex:1 1 100%}
.hc-save-bar #helpActionStatus:empty{display:none}
.hc-save-bar .btn{flex:1}
.hc-preview{position:sticky;top:16px}
.hc-preview #hcLiveCanvas iframe{height:calc(100vh - 190px)!important;min-height:480px}
@media(max-width:1100px){.hc-studio-layout{grid-template-columns:320px minmax(0,1fr)}}
@media(max-width:800px){.hc-studio-layout{grid-template-columns:1fr}.hc-preview{position:static}.hc-editor nav{overflow-x:auto}}

/* Printed reports: start at the top of the page and use the full width, so a
   short report fits one sheet instead of spilling onto a second. */
@media print{
  #appShell:has(.reports-host:not([hidden]) .report-document)>:not(.main),
  .main:has(>.reports-host:not([hidden]) .report-document)>:not(.reports-host),
  .reports-host .report-heading,.reports-host .report-controls{display:none!important}
  #appShell:has(.report-document),#appShell:has(.report-document)>.main{display:block!important;margin:0!important;padding:0!important;min-height:0!important;background:#fff!important}
  html:has(.report-document),html:has(.report-document) body{background:#fff!important}
  .report-document{width:auto!important;max-width:none!important}
  .report-document .report-brand{padding-bottom:8px!important;margin-bottom:10px!important}
  .report-document .report-title{margin:8px 0 12px!important}
  .report-document .report-kpis{grid-template-columns:repeat(var(--report-metric-count,4),minmax(0,1fr))!important;gap:8px!important;margin:0 0 10px!important}
  .report-document .report-kpis>*{padding:10px 12px!important}
  .report-document .report-chart-grid{grid-template-columns:1.5fr 1fr!important;gap:10px!important;margin:10px 0!important}
  .report-document .report-chart{padding:12px 14px!important;margin:0!important}
  .report-document .report-chart svg{height:120px!important}
  .report-document figcaption .report-metric-control{display:none!important}
  .report-document section,.report-document .report-takeaway{margin-top:10px!important;margin-bottom:10px!important;padding-top:10px!important;padding-bottom:10px!important}
  .report-document .report-footnote{margin-top:8px!important}
}
.db label.fsearch{max-width:none}

/* Customer feedback settings: one row per survey, one Save per row. */
.stg .fb-channel{margin-bottom:18px}
.stg .fb-lead{margin:0 0 14px;color:var(--ink-3)}
.stg .fb-warning{margin:0 0 14px;padding:10px 12px;border-radius:var(--gd-radius-m,8px);background:var(--pend-wash);color:var(--ink);font-size:13px}
.stg .fb-survey{padding:14px 16px;margin:0 0 10px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-l,12px);background:var(--sheet)}
.stg .fb-survey-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}
.stg .fb-survey-head h4{margin:0;font-size:14px}
.stg .fb-survey-head small{color:var(--ink-3)}
.stg .fb-survey-fields{display:grid;grid-template-columns:minmax(0,1fr) 170px auto;gap:12px;align-items:end}
.stg .fb-survey-fields label{margin:0}
.stg .fb-results-head{margin:16px 0 8px}
@media(max-width:700px){.stg .fb-survey-fields{grid-template-columns:1fr}}
dialog.gd-ask .btn{min-height:34px;padding:7px 14px;border:1px solid var(--rule);border-radius:var(--gd-radius-m,8px);background:var(--sheet);color:var(--ink);font:600 13px var(--ui);cursor:pointer}
dialog.gd-ask .btn:hover{background:var(--sheet-2)}
dialog.gd-ask .btn.sign{border-color:var(--sign);background:var(--sign);color:#fff}
dialog.gd-ask .btn.sign:hover{filter:brightness(1.06)}
dialog.gd-ask .btn:focus-visible{outline:2px solid var(--sign);outline-offset:2px}

/* Settings → Live chat & contact forms. */
.stg .lc-tabs{display:inline-flex;gap:2px;padding:3px;margin:0 0 16px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet-2)}
.stg .lc-tabs button{padding:7px 16px;border:0;border-radius:7px;background:none;font:600 13px var(--ui);color:var(--ink-3);cursor:pointer}
.stg .lc-tabs [aria-pressed=true]{background:var(--sheet);color:var(--ink);box-shadow:var(--gd-shadow-1)}
.stg .lc-picker{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 16px}
.stg .lc-pick{display:grid;gap:4px;min-width:170px;padding:10px 14px;border:1px solid var(--rule);border-radius:var(--gd-radius-l,12px);background:var(--sheet);font:inherit;color:var(--ink);text-align:left;cursor:pointer}
.stg .lc-pick[aria-pressed=true]{border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 16%,transparent)}
.stg .lc-pick small{color:var(--ink-3)}
.stg .lc-pick-new{border-style:dashed}
.stg .lc-chip{display:inline-block;padding:1px 8px;border-radius:999px;background:var(--sheet-2);color:var(--ink-3);font-size:11px;font-weight:600}
.stg .lc-chip.is-on{background:color-mix(in srgb,var(--ok) 14%,var(--sheet));color:var(--ok)}
.stg .lc-status{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:18px 20px;margin:0 0 14px;border:1px solid var(--rule);border-radius:var(--gd-radius-l,12px);background:var(--sheet)}
.stg .lc-status.is-on{border-color:color-mix(in srgb,var(--ok) 35%,var(--rule));background:color-mix(in srgb,var(--ok) 6%,var(--sheet))}
.stg .lc-status h3{margin:2px 0 4px;font-size:16px}
.stg .lc-status p{margin:0;color:var(--ink-3);font-size:13px}
.stg .lc-status .lc-state{display:flex;align-items:center;gap:6px;font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--ink-3)}
.stg .lc-status .lc-state i{width:8px;height:8px;border-radius:50%;background:var(--ink-4,#9aa3b2)}
.stg .lc-status.is-on .lc-state{color:var(--ok)}.stg .lc-status.is-on .lc-state i{background:var(--ok);box-shadow:0 0 0 4px color-mix(in srgb,var(--ok) 18%,transparent)}
.stg .lc-status .btn{flex:none}
.stg .lc-card{margin:0 0 14px}
.stg .lc-card>h3{margin-top:0}
.stg .lc-lead,.stg .lc-note{color:var(--ink-3);font-size:13px}
.stg .lc-lead{margin:0 0 12px}
.stg .lc-notice{padding:9px 12px;border-radius:var(--gd-radius-m,8px);background:color-mix(in srgb,var(--ok) 10%,var(--sheet));color:var(--ink)}
.stg .lc-fixed{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin:0 0 4px}
.stg .lc-fixed span{padding:4px 10px;border-radius:999px;background:var(--sheet-2);font-size:12px;font-weight:600;color:var(--ink-2)}
.stg .lc-fixed small{color:var(--ink-3)}
.stg #publicQuestions{margin:14px 0 10px}
.stg .lc-question{display:grid;grid-template-columns:minmax(0,1fr) 170px auto auto;gap:10px 12px;align-items:end;padding:12px 14px;margin:0 0 8px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2)}
.stg .lc-question label{margin:0}
.stg .lc-question .lc-required{display:flex!important;align-items:center;gap:6px;min-height:38px;white-space:nowrap}
.stg .lc-question .lc-choices{grid-column:1/-1}
.stg .lc-place{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 0;border-top:1px solid var(--rule-soft)}
.stg .lc-place:first-of-type{border-top:0;padding-top:0}
.stg .lc-place-stack{display:block}
.stg .lc-place h4{margin:0 0 3px;font-size:13.5px}
.stg .lc-place p{margin:0;color:var(--ink-3);font-size:13px;overflow-wrap:anywhere}
.stg .lc-code{display:flex;align-items:center;gap:10px;margin:10px 0 12px;padding:10px 12px;border:1px solid var(--rule);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2)}
.stg .lc-code code{flex:1;min-width:0;font:12px/1.5 ui-monospace,Menlo,Consolas,monospace;overflow-wrap:anywhere;user-select:all}
.stg .lc-link{padding:0;border:0;background:none;font:inherit;color:var(--sign);cursor:pointer;text-decoration:underline}
.stg .lc-colors{grid-template-columns:repeat(3,minmax(0,160px))}
.stg .lc-actions{position:sticky;bottom:0;z-index:2;display:flex;align-items:center;gap:10px;padding:12px 16px;margin:0 0 14px;border:1px solid var(--rule);border-radius:var(--gd-radius-l,12px);background:var(--sheet);box-shadow:var(--gd-shadow-2)}
.stg .lc-actions small{color:var(--ink-3)}
.stg .lc-preview-form{display:grid;gap:10px;max-width:520px;margin-top:14px}
@media(max-width:760px){.stg .lc-question{grid-template-columns:1fr 1fr}.stg .lc-question>label:first-child{grid-column:1/-1}.stg .lc-status,.stg .lc-place{flex-direction:column;align-items:stretch}.stg .lc-colors{grid-template-columns:1fr}}

/* Help Center studio: one-step publish. */
.hc-save-bar .hc-review-first,.hc-editor .hc-review-first{flex:1 1 100%;padding:2px 0;border:0;background:none;font:500 12px var(--ui);color:var(--ink-3);text-decoration:underline;cursor:pointer;text-align:center}
.hc-editor .help-announcement-editor .hc-review-first{flex:none;display:inline;margin-left:10px}
.hc-publication-control{display:flex;gap:8px;margin-top:16px}

/* Knowledge overview: one quiet line instead of a wall of empty cards. */
.knowledge-empty-note{grid-column:1/-1;margin:4px 0 0;padding:12px 16px;border:1px dashed var(--rule);border-radius:var(--gd-radius-l,12px);color:var(--ink-3);font-size:13px}
.knowledge-empty-note b{color:var(--ink-2);font-weight:600}
.kn .tree .thd .lbl{overflow:visible}

/* Live chat page: figures are buttons that filter the list. */
.chat-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}
.chat-kpis .chat-kpi{display:block;padding:18px 20px;border:1px solid var(--rule);border-radius:var(--gd-radius-l,12px);background:var(--sheet);font:inherit;color:var(--ink);text-align:left;cursor:pointer;transition:border-color var(--gd-fast,.15s),box-shadow var(--gd-fast,.15s)}
.chat-kpis .chat-kpi:hover{border-color:color-mix(in srgb,var(--sign) 40%,var(--rule));box-shadow:var(--gd-shadow-2)}
.chat-kpis .chat-kpi[aria-pressed=true]{border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 14%,transparent)}
.chat-kpis .chat-kpi small{display:block;font-size:12px;color:var(--ink-3)}
.chat-kpis .chat-kpi b{display:block;margin-top:6px;font-size:28px;letter-spacing:-.02em}
@media(max-width:700px){.chat-kpis{grid-template-columns:1fr}.chat-kpis .chat-kpi{display:flex;align-items:center;justify-content:space-between;padding:12px 16px}.chat-kpis .chat-kpi b{margin:0;font-size:22px}}

/* Help Center studio, round 5 (2026-11-13). */
.hc-editor .help-announcement-editor .setup-box{position:relative;padding:14px}
.hc-editor .banner-options .setup-fields{display:grid;grid-template-columns:1fr;gap:10px;margin:0 0 12px}
.hc-editor .banner-options .setup-fields label,.hc-editor .banner-options .setup-fields label:first-child{grid-column:auto;margin:0}
.hc-editor .banner-options input[type=datetime-local]{min-width:0;font-size:13px;padding:9px 10px}
.hc-editor .banner-format{display:flex;gap:6px;margin:4px 0 8px;padding-top:12px;border-top:1px solid var(--rule-soft)}
.hc-editor .banner-format .btn{min-width:38px;padding:5px 10px}
.hc-editor .banner-link{position:absolute;left:14px;right:14px;z-index:5;margin:0;background:var(--sheet);box-shadow:var(--gd-shadow-3,0 16px 40px #0002)}
.hc-editor .banner-link input{background:var(--sheet)}
.hc-theme-gallery{grid-template-columns:1fr 1fr}
.hc-theme-style{margin-left:4px;padding:1px 7px;border-radius:999px;background:var(--sheet-2);font-size:10px;font-weight:600;color:var(--ink-3);vertical-align:1px}
.hc-theme-soon{display:grid;gap:6px;align-content:center;grid-column:1/-1;padding:12px 14px;border:1px dashed var(--rule);border-radius:12px;color:var(--ink-3);font-size:12px}
.hc-theme-soon strong{color:var(--ink-2);font-size:12.5px}
.hc-theme-soon small{font-size:11px;line-height:1.5}
/* Theme thumbnails sketch each layout: i = headline, b = search, em = topics. */
.hc-theme-mini.hc-theme-mini{position:relative;justify-items:center;border-radius:7px}
/* Thumbnails mirror the four layouts: every one has the search box centered. */
.hc-theme-classic{background:linear-gradient(#10302b 0,#10302b 60%,#f6f9f8 60%)}
.hc-theme-classic i{width:50%;height:6px;background:#fff}
.hc-theme-classic b{width:72%;height:12px;border:0;border-radius:6px;background:#fff}
.hc-theme-classic em{width:100%;height:16px;background:repeating-linear-gradient(90deg,#fff 0,#fff 30%,transparent 30%,transparent 35%);border-radius:3px}
.hc-theme-atlas{background:linear-gradient(#ff5a36 0,#ff5a36 62%,#fffaf3 62%)}
.hc-theme-atlas i{width:80%;height:10px;border-radius:2px;background:#16130f}
.hc-theme-atlas b{width:66%;height:11px;border:2px solid #16130f;border-radius:2px;background:#fff;box-shadow:2px 2px 0 #16130f}
.hc-theme-atlas em{width:100%;height:16px;background:repeating-linear-gradient(90deg,#16130f 0,#16130f 30%,transparent 30%,transparent 35%)}
.hc-theme-commons{background:#fdfcfa}
.hc-theme-commons i{width:56%;height:6px;background:#2b2540}
.hc-theme-commons b{width:62%;height:10px;border:1px solid #b9b3cc;border-radius:999px;background:#fff}
.hc-theme-commons em{width:84%;height:20px;background:repeating-linear-gradient(180deg,#d9d4ea 0,#d9d4ea 3px,transparent 3px,transparent 7px)}
.hc-theme-focus{background:linear-gradient(#0f1b33 0,#0f1b33 46%,#f5f7fb 46%)}
.hc-theme-focus i{width:34%;height:5px;background:#fff}
.hc-theme-focus b{width:66%;height:10px;border:0;border-radius:3px;background:#fff}
.hc-theme-focus em{width:100%;height:24px;background:linear-gradient(90deg,#c9d6f5 0,#c9d6f5 22%,transparent 22%,transparent 28%,#fff 28%);border-radius:3px}
.hc-upload{display:grid;gap:10px;margin:0 0 6px;padding:12px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2)}
.hc-upload input[type=file]{width:100%;margin:0;background:var(--sheet)}
.hc-upload-actions{display:flex;gap:8px}
.hc-upload .hc-hint{margin:0}
.hc-channel{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:14px 0;border-top:1px solid var(--rule-soft)}
.hc-channel h3{margin:0 0 2px!important;font-size:13.5px}
.hc-channel .hc-hint{margin:0}
.hc-channel-pick{margin:0!important;flex:none;width:140px}
.hc-channel .btn{flex:none}
.hc-channel-note{margin:-6px 0 10px!important;color:var(--ok)!important}
.hc-code-help{margin:0 0 14px;padding:12px 14px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-m,8px);background:var(--sheet-2);font-size:12.5px;line-height:1.55}
.hc-code-help p{margin:0 0 8px}.hc-code-help p:last-child{margin:0}
.hc-flash{animation:hcFlash 1.6s ease-out}
@keyframes hcFlash{0%,35%{box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 45%,transparent);border-radius:8px}100%{box-shadow:0 0 0 3px transparent}}
@media(prefers-reduced-motion:reduce){.hc-flash{animation:none;outline:2px solid var(--sign)}}

/* Import from Zendesk. */
.stg .zb-card{margin:0 0 14px}.stg .zb-card>h3{margin-top:0}
.stg .zb-steps{margin:0 0 10px;padding-left:20px;line-height:1.7}
.stg .zb-note{margin:8px 0 0;color:var(--ink-3);font-size:13px}
.stg .zb-progress{height:10px;margin:4px 0 10px;border-radius:999px;background:var(--sheet-2);overflow:hidden}
.stg .zb-progress i{display:block;height:100%;border-radius:999px;background:var(--sign);transition:width .4s ease}
.stg .zb-state{margin:0 0 12px;font-weight:600}
.stg .zb-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:10px;margin:0 0 10px}
.stg .zb-stat{padding:12px 14px;border:1px solid var(--rule-soft);border-radius:var(--gd-radius-l,12px);background:var(--sheet)}
.stg .zb-stat b{display:block;font-size:22px;letter-spacing:-.02em}.stg .zb-stat span{font-size:12px;color:var(--ink-3)}
.stg .zb-stat[data-tone=good] b{color:var(--ok)}.stg .zb-stat[data-tone=warn] b{color:var(--pend)}.stg .zb-stat[data-tone=alert] b{color:var(--a1)}
.stg .zb-detail{margin:8px 0;font-size:13px}.stg .zb-detail ul{margin:8px 0 0;padding-left:20px;max-height:220px;overflow:auto}
.stg .zb-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:14px}
.gx .pill.imported{background:var(--sheet-2);color:var(--ink-3);font-weight:600}
.stg .zb-two{display:grid;grid-template-columns:1fr 1fr;gap:8px 28px;margin-bottom:8px}
.stg .zb-limits h4{margin:10px 0 6px;font-size:13px}
.stg .zb-limits ul{margin:0;padding-left:18px;line-height:1.65;font-size:13px;color:var(--ink-2)}
@media(max-width:760px){.stg .zb-two{grid-template-columns:1fr}}

/* Feature requests & community review (settings/community.js) */
/* A channel's switch and settings on one Help Center (Feature requests, Community; 2026-11-16) */
.cm-channel{display:grid;grid-template-columns:minmax(0,1fr);gap:14px;padding:20px;margin:14px 0}
.cm-channel-head>div{min-width:0}
.cm-channel-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-start}
.cm-channel-head h3{margin:2px 0 4px;font-size:16px}.cm-channel-head p{margin:0;color:var(--ink-2,#44506a);max-width:64ch}
.cm-channel-note,.cm-channel-link{margin:0}.cm-channel-link a{overflow-wrap:anywhere}
.cm-channel-settings{display:grid;gap:16px;padding-top:14px;border-top:1px solid var(--rule-soft,#e8ebf2)}
#appShell .stg .cm-channel-settings label{display:grid;gap:6px;margin:0;font-size:13px}
#appShell .stg .cm-channel-settings small{color:var(--ink-2,#44506a);line-height:1.4;font-weight:400;font-size:12.5px}
.cm-channel-link a{color:var(--sign)}
.cm-section-title{margin:30px 0 4px;font-size:17px}
.hc-channel-links{display:flex;flex-wrap:wrap;gap:8px;flex:none}
.cm-filters{display:flex;flex-wrap:wrap;gap:8px;margin:16px 0}
.cm-post{display:grid;gap:12px;padding:20px;margin:14px 0}
.cm-post .cm-head{display:flex;justify-content:space-between;gap:16px;align-items:flex-start}
.cm-post .cm-head h3{margin:2px 0 0;font-size:16px}
.cm-post .cm-meta{display:flex;gap:8px;align-items:center;flex:none}
.cm-post .cm-body{margin:0;white-space:pre-wrap;overflow-wrap:anywhere}
.cm-tag{display:inline-block;padding:2px 8px;border-radius:999px;font-size:11px;font-weight:600;background:var(--gd-surface-2,#eef1f6);color:var(--ink-2,#44506a)}
.cm-tag.pending{background:#fff3d6;color:#7a4b00}.cm-tag.published{background:#e3f6ec;color:#17603f}.cm-tag.rejected{background:#fde8e8;color:#8a2424}
.cm-votes{font-size:12px;color:var(--ink-2,#44506a)}
.cm-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:14px;align-items:start}
.cm-fields label,.cm-thread label{display:grid;gap:6px;font-size:13px}
.cm-fields small{color:var(--ink-2,#44506a);line-height:1.4}
.cm-inline{display:flex;gap:8px}.cm-inline input{flex:1;min-width:0}
.cm-shot img{max-width:min(100%,560px);max-height:360px;border:1px solid var(--rule,#dfe3ec);border-radius:10px;display:block}
.cm-thread{border-top:1px solid var(--rule,#dfe3ec);padding-top:12px}
.cm-thread summary{cursor:pointer;font-weight:600;font-size:13px}
.cm-thread ul{list-style:none;margin:12px 0;padding:0;display:grid;gap:10px}
.cm-comment{display:flex;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid var(--rule,#dfe3ec);border-radius:10px}
.cm-comment.staff{background:var(--gd-surface-2,#f4f6fb)}
.cm-comment p{margin:4px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}
.cm-comment-actions{display:flex;gap:6px;flex:none;align-items:flex-start}
.cm-thread textarea{width:100%}.cm-thread>.btn{margin-top:8px}
@media (max-width:640px){.cm-post .cm-head,.cm-comment{flex-direction:column}}
/* The shared icon sprite (desk-sprite.js) takes no space. */
svg.gd-sprite{position:absolute;width:0;height:0;overflow:hidden}

/* Tickets panel, 2026-11-14: three plain lists first, saved queues next,
   rarely used views folded away. */
#appShell .gx .vpane .vmain{display:grid;gap:2px;padding:6px 0 10px;margin-bottom:6px;border-bottom:1px solid var(--rule-soft)}
#appShell .gx .vpane .vrow.vrow-main{min-height:40px;font-size:14px;font-weight:500;color:var(--ink)}
#appShell .gx .vpane .vrow.vrow-main[aria-current=true]{font-weight:650}
#appShell .gx .vpane .vfold{margin-top:6px}
#appShell .gx .vpane .vfold-h{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 6px 4px 4px}
#appShell .gx .vpane .vfold-btn{display:inline-flex;align-items:center;gap:6px;padding:4px 6px;border-radius:6px;font:600 12px var(--ui);color:var(--ink-3)}
#appShell .gx .vpane .vfold-btn:hover{background:var(--sheet-2);color:var(--ink)}
#appShell .gx .vpane .vfold-btn svg{width:14px;height:14px;transition:transform var(--gd-fast) var(--gd-ease)}
#appShell .gx .vpane .vfold[data-folded=true] .vfold-btn svg{transform:rotate(-90deg)}
#appShell .gx .vpane .vfold-link{padding:3px 8px;border-radius:6px;font:500 12px var(--ui);color:var(--sign)}
#appShell .gx .vpane .vfold-link:hover{background:var(--sign-wash)}
#appShell .gx .vpane .vfold-dot{display:inline-block;width:6px;height:6px;margin-left:4px;border-radius:50%;background:var(--sign);vertical-align:middle}
#appShell .gx .vpane .vfold-body .note{margin:4px 10px 8px;font-size:12.5px;line-height:1.45;color:var(--ink-3)}
@media(prefers-reduced-motion:reduce){#appShell .gx .vpane .vfold-btn svg{transition:none}}

/* ==========================================================================
   Chat as chat, 2026-11-14 (chat-room.js, live-chat.js, desk/chat-dock.js)
   A conversation in bubbles: the customer on the left, the team on the right.
   Rounder and softer than the ticket screen on purpose, same tokens.
   ========================================================================== */
.cr{display:flex;flex-direction:column;min-width:0;min-height:0;height:100%;background:var(--sheet);font-family:var(--ui);color:var(--ink)}
.cr-head{display:flex;align-items:center;gap:10px;flex:none;min-height:60px;padding:10px 16px;border-bottom:1px solid var(--rule-soft)}
.cr-who{display:flex;align-items:center;gap:10px;flex:1;min-width:0}
.cr-title{display:grid;min-width:0;line-height:1.3}
.cr-title b{font-size:15px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cr-state{font-size:12.5px;color:var(--ink-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cr-state.is-waiting{color:var(--pend);font-weight:600}
.cr-actions{display:flex;align-items:center;gap:6px;flex:none}
.cr-icon{display:grid;place-items:center;flex:none;width:30px;height:30px;border-radius:50%;font-size:22px;line-height:1;color:var(--ink-2)}
.cr-icon:hover{background:var(--sheet-2);color:var(--ink)}
.cr-avatar,.lc-avatar{display:grid;place-items:center;flex:none;width:38px;height:38px;border-radius:50%;background:color-mix(in srgb,var(--sign) 14%,var(--sheet));color:var(--sign);font:650 13px var(--ui);letter-spacing:.02em}
.cr-avatar.sm{width:28px;height:28px;font-size:11px;align-self:flex-end}
.cr-avatar.is-spacer{visibility:hidden}
.cr-thread{flex:1;min-height:0;overflow-y:auto;display:flex;flex-direction:column;gap:3px;padding:18px 18px 10px;background:color-mix(in srgb,var(--ground) 60%,var(--sheet));scroll-behavior:smooth}
.cr-thread:focus-visible{outline:2px solid var(--sign);outline-offset:-2px}
.cr-day{align-self:center;margin:10px 0 8px;padding:2px 12px;border-radius:999px;background:var(--sheet);border:1px solid var(--rule-soft);font-size:12px;color:var(--ink-3)}
.cr-row{display:flex;gap:8px;max-width:100%}
.cr-row.is-lead{margin-top:10px}
.cr-col{display:flex;flex-direction:column;gap:3px;min-width:0;max-width:min(78%,560px)}
.cr-meta{font-size:12px;color:var(--ink-3);padding:0 6px}
.cr-bubble{padding:9px 14px;border-radius:18px;font-size:14.5px;line-height:1.5;white-space:pre-wrap;overflow-wrap:anywhere}
.cr-files{font-size:12px;color:var(--ink-3);padding:0 6px}
/* Customer: left, neutral. */
.cr-them{justify-content:flex-start}
.cr-them .cr-bubble{background:var(--sheet);border:1px solid var(--rule);color:var(--ink);border-bottom-left-radius:6px}
/* Team: right, in the product colour. */
.cr-us,.cr-note{justify-content:flex-end}
.cr-us .cr-col,.cr-note .cr-col{align-items:flex-end}
.cr-us .cr-bubble{background:var(--sign);color:#fff;border-bottom-right-radius:6px}
/* Internal note: right, but plainly not something the customer sees. */
.cr-note .cr-bubble{background:var(--pend-wash,#fff6dc);color:var(--ink);border:1px dashed color-mix(in srgb,var(--pend) 55%,transparent);border-bottom-right-radius:6px}
.cr-note .cr-meta{color:var(--pend);font-weight:600}
.cr-info{align-self:center;max-width:min(86%,520px);margin:10px 0;padding:10px 14px;border:1px solid var(--rule-soft);border-radius:12px;background:var(--sheet);font-size:13px;color:var(--ink-2);text-align:left}
.cr-info b{display:block;font-size:12px;color:var(--ink-3);font-weight:600}
.cr-info p{margin:4px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}
.cr-empty{margin:auto;color:var(--ink-3);font-size:14px;text-align:center}
.cr-typing{flex:none;min-height:20px;margin:0;padding:0 20px;background:color-mix(in srgb,var(--ground) 60%,var(--sheet));font-size:12.5px;font-style:italic;color:var(--ink-3)}
.cr-foot{flex:none;padding:12px 16px 14px;border-top:1px solid var(--rule-soft);background:var(--sheet)}
.cr-modes{display:inline-flex;gap:2px;margin-bottom:8px;padding:3px;border-radius:999px;background:var(--sheet-2)}
.cr-modes button{padding:5px 12px;border-radius:999px;font:500 12.5px var(--ui);color:var(--ink-2)}
.cr-modes button[aria-pressed=true]{background:var(--sheet);color:var(--ink);font-weight:600;box-shadow:0 1px 2px rgba(0,0,0,.08)}
.cr-box{display:flex;align-items:flex-end;gap:8px;padding:6px 6px 6px 16px;border:1px solid var(--rule);border-radius:24px;background:var(--sheet);transition:border-color var(--gd-fast,.12s) ease,box-shadow var(--gd-fast,.12s) ease}
.cr-box:focus-within{border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 16%,transparent)}
.cr .cr-box textarea{flex:1;min-width:0;min-height:36px;max-height:160px;padding:8px 0;border:0;border-radius:0;background:transparent;box-shadow:none;outline:none;resize:none;font:400 14.5px/1.45 var(--ui);color:var(--ink);field-sizing:content}
.cr .cr-send{flex:none;min-height:36px;padding:0 18px;border-radius:999px}
.cr-compose.is-note .cr-box{border-style:dashed;border-color:color-mix(in srgb,var(--pend) 55%,transparent);background:var(--pend-wash,#fff6dc)}
.cr-hint{margin:8px 4px 0;font-size:12px;color:var(--ink-3)}
.cr-error{margin:6px 4px 0;font-size:13px;color:var(--a1)}
.cr-error:empty{display:none}
.cr-end,.cr-ended{display:grid;gap:8px;padding:14px 16px;border:1px solid var(--rule);border-radius:16px;background:var(--sheet-2)}
.cr-end p,.cr-ended p{margin:0;font-size:13px;line-height:1.5;color:var(--ink-2)}
.cr-end label{display:grid;gap:6px;font-size:12.5px;color:var(--ink-2)}
.cr .cr-end textarea{width:100%;min-height:56px;padding:8px 12px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet);font:400 14px/1.45 var(--ui);resize:vertical}
.cr-end-actions{display:flex;justify-content:flex-end;gap:8px}
.cr-ended .btn{justify-self:start}
/* Small version, inside the Tickets side panel. */
.cr-mini .cr-head{min-height:52px;padding:8px 10px;flex-wrap:wrap}
.cr-mini .cr-avatar{width:32px;height:32px;font-size:12px}
.cr-mini .cr-thread{padding:12px 12px 8px}
.cr-mini .cr-col{max-width:84%}
.cr-mini .cr-bubble{font-size:14px;padding:8px 12px}
.cr-mini .cr-foot{padding:10px 10px 12px}
#appShell .gd-chat-dock.has-room{padding:0}
#appShell .gd-chat-room{display:flex;flex:1;min-height:0}
#appShell .gd-chat-room .cr{flex:1}
#appShell .gx .vpane .gd-chat-group{margin:0 0 6px;padding-bottom:8px;border-bottom:1px solid var(--rule-soft)}
#appShell .gx .vpane .gd-chat-row .cnt.is-waiting{color:var(--pend);font-weight:600}
#appShell .gd-chat-strip .gd-chat-view{margin-left:auto}

/* The Live chat page: list, conversation, customer. */
.chat-console.chat-console{display:flex;flex-direction:column;height:100vh;min-height:0;padding:0;background:var(--ground)}
.lc-top{display:flex;align-items:center;justify-content:space-between;gap:16px;flex:none;padding:18px 28px 14px}
.lc-top h1{display:flex;align-items:center;gap:10px;margin:0;font:700 22px var(--ui);letter-spacing:-.02em}
.lc-ws{display:flex;align-items:center;gap:10px;font-size:13px;color:var(--ink-3)}
.lc-ws select{min-width:200px}
.lc-error{margin:0 28px;color:var(--a1);font-size:13px}
.lc-error:empty{display:none}
.lc-grid{flex:1;min-height:0;display:grid;grid-template-columns:320px minmax(0,1fr) 300px;gap:14px;padding:0 28px 24px}
.lc-list,.lc-room,.lc-details{min-height:0;border:1px solid var(--rule);border-radius:18px;background:var(--sheet);overflow:hidden}
.lc-list{display:flex;flex-direction:column}
.lc-filters{display:flex;flex-wrap:wrap;gap:6px;flex:none;padding:12px;border-bottom:1px solid var(--rule-soft)}
.lc-filters button{display:inline-flex;align-items:center;gap:6px;padding:5px 11px;border:1px solid var(--rule);border-radius:999px;font:500 12.5px var(--ui);color:var(--ink-2);background:var(--sheet)}
.lc-filters button span{font-variant-numeric:tabular-nums;color:var(--ink-3)}
.lc-filters button:hover{border-color:color-mix(in srgb,var(--sign) 40%,var(--rule))}
.lc-filters button[aria-pressed=true]{border-color:var(--sign);background:var(--sign-wash);color:var(--sign);font-weight:600}
.lc-filters button[aria-pressed=true] span{color:inherit}
.lc-items{flex:1;min-height:0;overflow-y:auto;padding:6px}
.lc-item{display:flex;gap:10px;width:100%;padding:10px;border-radius:12px;text-align:left;color:var(--ink)}
.lc-item:hover{background:var(--sheet-2)}
.lc-item[aria-current=true]{background:var(--sign-wash)}
.lc-item-main{display:grid;gap:1px;min-width:0;flex:1}
.lc-item-top{display:flex;justify-content:space-between;gap:8px;align-items:baseline}
.lc-item-top b{font-size:14px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.lc-item-top time{flex:none;font-size:12px;color:var(--ink-3)}
.lc-item-sub{font-size:13px;color:var(--ink-2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.lc-item-state{font-size:12px;color:var(--ink-3)}
.lc-item.is-waiting .lc-avatar{box-shadow:0 0 0 2px var(--sheet),0 0 0 4px var(--pend)}
.lc-item.is-waiting .lc-item-state{color:var(--pend);font-weight:600}
.lc-none{margin:0;padding:18px 14px;font-size:13px;line-height:1.5;color:var(--ink-3)}
.lc-room{display:flex;flex-direction:column}
.lc-room-host{flex:1;min-height:0;display:flex;flex-direction:column}
.lc-back{display:none;align-self:flex-start;margin:10px 12px 0}
.lc-empty{margin:auto;max-width:380px;padding:24px;text-align:center}
.lc-empty h2{margin:0 0 8px;font:650 18px var(--ui);letter-spacing:-.01em}
.lc-empty p{margin:0;font-size:14px;line-height:1.55;color:var(--ink-3)}
.lc-details{overflow-y:auto;padding:18px}
.lc-details:empty{visibility:hidden}
.lc-card{display:grid;justify-items:center;gap:4px;padding-bottom:16px;border-bottom:1px solid var(--rule-soft);text-align:center}
.lc-avatar.lg{width:56px;height:56px;font-size:18px;margin-bottom:6px}
.lc-card h2{margin:0;font:650 16px var(--ui)}
.lc-card p{margin:0;font-size:13px;color:var(--ink-3);overflow-wrap:anywhere}
.lc-card .btn{margin-top:10px}
.lc-facts{display:grid;gap:8px;margin:0;padding:16px 0;border-bottom:1px solid var(--rule-soft)}
.lc-facts:last-child{border-bottom:0}
.lc-facts h3{margin:0 0 2px;font:650 13px var(--ui);color:var(--ink)}
.lc-facts div{display:flex;justify-content:space-between;gap:12px;font-size:13px}
.lc-facts dt{color:var(--ink-3);flex:none}
.lc-facts dd{margin:0;text-align:right;overflow-wrap:anywhere;color:var(--ink)}
.lc-facts .btn{justify-self:start;margin-top:4px}
.lc-muted{margin:0;font-size:12px;line-height:1.45;color:var(--ink-3)}
@media(max-width:1180px){.lc-grid{grid-template-columns:290px minmax(0,1fr)}.lc-details{display:none}}
@media(max-width:900px){
  .chat-console.chat-console{height:calc(100dvh - 54px)}
  .lc-top{padding:12px 14px 10px}.lc-top h1{font-size:19px}.lc-ws select{min-width:0}
  .lc-grid{grid-template-columns:minmax(0,1fr);padding:0 10px 10px}
  .lc-grid[data-view=list] .lc-room,.lc-grid[data-view=room] .lc-list{display:none}
  .lc-back{display:inline-flex}
  .cr-col{max-width:86%}
}
@media(prefers-reduced-motion:reduce){.cr-thread{scroll-behavior:auto}.cr-box{transition:none}}
/* The page's older button rules are broad; these win for the new parts. */
.chat-console .lc-item{border:0;background:transparent;box-shadow:none;min-height:0;font:inherit}
.chat-console .lc-item:hover{background:var(--sheet-2)}
.chat-console .lc-item[aria-current=true]{background:var(--sign-wash)}
.chat-console .lc-filters button{min-height:0;box-shadow:none}
.chat-console .btn.lc-back{display:none}
.cr .cr-modes button{border:0;background:transparent;min-height:0;box-shadow:none}
.cr .cr-modes button[aria-pressed=true]{background:var(--sheet);box-shadow:0 1px 2px rgba(0,0,0,.08)}
.cr .btn.cr-send{border-radius:999px;min-height:36px;padding:0 18px}
.cr .cr-icon{border:0;background:transparent;min-height:0;padding:0}
.cr .cr-actions .btn{min-height:32px;padding:5px 12px;font-size:13px}
@media(max-width:900px){.chat-console .btn.lc-back{display:inline-flex}}
#appShell .gd-chat-room{min-width:0;width:100%}
#appShell .gd-chat-room .cr{min-width:0;width:100%}
.cr-mini .cr-actions{flex:1 1 100%;flex-wrap:wrap}
.cr-mini .cr-who{flex:1 1 0}
.cr-mini .cr-box{padding-left:12px}
.lc-grid{grid-template-rows:minmax(0,1fr)}
@media(max-width:900px){.chat-console .lc-grid{min-height:calc(100dvh - 150px)}.chat-console .lc-room,.chat-console .lc-list{min-height:calc(100dvh - 160px)}}

/* Audience labels and icon shapes distinguish knowledge articles and internal playbooks. */
#appShell #kView[data-kind] #kTop{border-top:3px solid var(--sign)}
#appShell #kView[data-kind=playbook] #kTop:has(.knowledge-heading){background:linear-gradient(var(--sign-wash),var(--sheet) 78%)}
#appShell .kn-id{display:flex;align-items:center;gap:14px;min-width:0}
#appShell .kn-mark{display:grid;place-items:center;flex:none;width:44px;height:44px;border-radius:12px;background:var(--sign);color:var(--sign-ink)}
#appShell .kn-mark svg{width:22px;height:22px}
#appShell #kView[data-kind=playbook] .kn-mark{border-radius:50%}
#appShell .kn-aud{margin:2px 0 0;font-size:13px;line-height:1.4;color:var(--ink-3)}
#appShell .kn-aud b{display:inline-block;margin-right:8px;padding:1px 8px;border-radius:999px;background:var(--sign-wash);color:var(--sign);font-weight:650;font-size:12px}
#appShell #kView[data-kind=playbook] .kn-aud b{background:var(--sign);color:var(--sign-ink)}
/* In the editor: a chip that says which kind of document this is. */
#appShell .kn-kind{display:inline-flex;align-items:center;gap:6px;flex:none;padding:3px 10px;border-radius:999px;background:var(--sign-wash);color:var(--sign);font:650 12px var(--ui);white-space:nowrap}
#appShell .kn-kind svg{width:14px;height:14px}
#appShell #kView[data-kind=playbook] .kn-kind{background:var(--sign);color:var(--sign-ink)}
/* In the "new document" dialog, which sits outside the section. */
.kn-audience{display:flex;align-items:center;gap:10px;margin:0 0 14px;padding:10px 14px;border-radius:10px;font-size:13.5px;line-height:1.45;background:var(--sign-wash);color:var(--ink)}
.kn-audience svg{flex:none;width:18px;height:18px;color:var(--sign)}
@media(max-width:700px){#appShell .kn-aud{display:none}#appShell .kn-mark{width:36px;height:36px;border-radius:10px}}

/* ==========================================================================
   One ticket table everywhere, 2026-11-15 (desk/ticket-columns.js)
   All tickets, My tickets, Unassigned and every queue share these columns.
   Column headings sort; each ticket is a clearly separated row.
   ========================================================================== */
#appShell .gx .ticket-table th.col-ticket{width:30%}
#appShell .gx .ticket-table th.col-requester{width:15%}
#appShell .gx .ticket-table th.col-org{width:14%}
#appShell .gx .ticket-table th.col-status{width:10%}
#appShell .gx .ticket-table th.col-priority{width:9%}
#appShell .gx .ticket-table th.col-assignee{width:12%}
#appShell .gx .ticket-table th.col-due{width:10%}
#appShell .gx .ticket-table{min-width:980px}
#appShell .gx .ticket-table th{padding:0}
#appShell .gx .ticket-table th.queue-select{padding:12px}
#appShell .gx .ticket-table .col-sort{display:flex;align-items:center;gap:6px;width:100%;min-height:42px;padding:10px 16px;border:0;border-radius:0;background:transparent;font:600 12px var(--ui);color:var(--ink-3);text-align:left;cursor:pointer}
#appShell .gx .ticket-table th:first-child .col-sort{padding-left:28px}
#appShell .gx .ticket-table .col-sort:hover{color:var(--ink);background:color-mix(in srgb,var(--ink) 5%,transparent)}
#appShell .gx .ticket-table .col-sort:focus-visible{outline:2px solid var(--sign);outline-offset:-2px}
#appShell .gx .ticket-table th[aria-sort=ascending] .col-sort,#appShell .gx .ticket-table th[aria-sort=descending] .col-sort{color:var(--sign)}
#appShell .gx .ticket-table .col-sort-mark{display:inline-flex;width:14px;height:14px;font-size:14px}
#appShell .gx .ticket-table tbody tr{border-bottom:1px solid var(--rule)}
#appShell .gx .ticket-table tbody td{border-bottom:1px solid var(--rule);vertical-align:middle}
#appShell .gx .ticket-table td.col-org{font-size:13px;color:var(--ink-2);overflow:hidden;text-overflow:ellipsis}
/* Queues use the same table. */
#appShell .gx table.queue-list{margin:0;border:1px solid var(--rule);border-radius:10px;border-collapse:separate;border-spacing:0;overflow:hidden;background:var(--sheet)}
#appShell .gx table.queue-list tr.lr{display:table-row;padding:0;cursor:pointer}
#appShell .gx table.queue-list tr.lr>td{padding:12px 16px}
#appShell .gx table.queue-list tr.lr>td:first-child{padding-left:28px}
#appShell .gx table.queue-list tr.lr:last-child>td{border-bottom:0}
#appShell .gx table.queue-list tr.lr[aria-selected=true]>td{background:var(--sign-wash)}
#appShell .gx table.queue-list tr.lr[aria-selected=true]>td:first-child{box-shadow:inset 3px 0 0 var(--sign)}
#appShell .gx table.queue-list .chips{display:flex;flex-wrap:wrap;gap:4px;margin-top:4px}
#appShell .gx table.queue-list tr.queue-group>th{padding:10px 16px 8px 28px;background:var(--sheet-2);border-bottom:1px solid var(--rule);font:650 12px var(--ui);color:var(--ink-2);text-align:left}
#appShell .gx table.queue-list tr.queue-group>th small{margin-left:8px;font-weight:500;color:var(--ink-3)}
#appShell .gx table.queue-list tr.queue-group.o>th span{color:var(--a1)}
#appShell .gx .queue-sorted{display:flex;align-items:center;gap:10px;margin:0 0 10px;font-size:13px;color:var(--ink-2)}
#appShell .gx #dVMain .queue-table-wrap{overflow:auto;border-radius:10px}
#appShell .gx #dLayout button{display:inline-flex;align-items:center;gap:6px}
#appShell .gx #dLayout button svg{width:14px;height:14px}
@media(max-width:820px){
  #appShell .gx .ticket-table{min-width:0}
  #appShell .gx table.queue-list,#appShell .gx table.queue-list tbody{display:block}
  #appShell .gx table.queue-list thead{display:none}
  #appShell .gx table.queue-list tr.lr{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 10px;padding:12px 14px;border-bottom:1px solid var(--rule)}
  #appShell .gx table.queue-list tr.lr>td{padding:0;border:0}
  #appShell .gx table.queue-list tr.lr>td:first-child{padding:0;grid-column:1/-1}
  #appShell .gx table.queue-list tr.lr>td.col-assignee,#appShell .gx table.queue-list tr.lr>td.col-org:has(.muted){display:none}
  #appShell .gx table.queue-list tr.queue-group{display:block}
  #appShell .gx table.queue-list tr.queue-group>th{display:block;padding:10px 14px 8px}
}
#appShell .gx table.queue-list{min-width:860px}
#appShell .gx table.queue-list .person-mark{display:none}
#appShell .gx table.queue-list tr.lr>td{padding:11px 12px}
#appShell .gx table.queue-list .col-sort{padding:10px 12px}
@media(max-width:820px){#appShell .gx table.queue-list{min-width:0}}

/* Reply box, 2026-11-15: the whole box is the writing area, and an internal
   note is one even colour from edge to edge (no inner frame or corner seam). */
#appShell #dDesk .composer .editor.ticket-rich-editor{border:0;border-radius:0;box-shadow:none;cursor:text}
#appShell #dDesk .composer .editor.ticket-rich-editor .ticket-message-canvas{border:0;border-radius:0}
#appShell #dDesk .composer.inote{background:var(--pend-wash)}
#appShell #dDesk .composer.inote .editor.ticket-rich-editor,#appShell #dDesk .composer.inote .ticket-message-canvas,#appShell #dDesk .composer.inote .reply-tools,#appShell #dDesk .composer.inote .cf{background:transparent;box-shadow:none;border-left:0;border-right:0}
#appShell #dDesk .composer.inote .ct{background:var(--sheet)}

/* ==========================================================================
   Live chat extras, 2026-11-15
   Country flags that are flags on every system, light formatting and files
   in the chat, articles next to the chat, and the Live chat overview.
   ========================================================================== */
/* Only the flag characters come from this font; see fonts/TwemojiCountryFlags.LICENSE.txt. */
@font-face{font-family:"Twemoji Country Flags";src:url("fonts/TwemojiCountryFlags.woff2") format("woff2");unicode-range:U+1F1E6-1F1FF;font-display:swap}
.gd-flag{font-family:"Twemoji Country Flags","Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif;font-size:1.2em;line-height:1;vertical-align:-.12em;margin-right:2px}

/* Formatted messages and links inside a bubble */
.cr-bubble.is-rich{white-space:normal}
.cr-bubble p,.cr-bubble ul,.cr-bubble ol,.cr-bubble blockquote,.cr-bubble pre{margin:0}
.cr-bubble.is-rich>*+*{margin-top:6px}
.cr-bubble ul,.cr-bubble ol{padding-left:20px}
.cr-bubble li+li{margin-top:2px}
.cr-bubble blockquote{padding-left:10px;border-left:2px solid currentColor}
.cr-bubble pre{font:12.5px/1.5 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;white-space:pre-wrap}
.cr-bubble .rm-strong{font-weight:650}
.cr-bubble a{color:inherit;text-decoration:underline;text-underline-offset:2px}
.cr-bubble a:hover{text-decoration-thickness:2px}

/* Files on a message */
.cr .cr-files{display:flex;flex-wrap:wrap;gap:6px;padding:2px 0 0}
.cr-us .cr-files,.cr-note .cr-files{justify-content:flex-end}
.cr .cr-file{display:inline-flex;align-items:center;gap:6px;max-width:260px;min-height:0;padding:5px 10px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet);box-shadow:none;font:500 12.5px var(--ui);color:var(--ink-2)}
.cr .cr-file span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cr .cr-file small{flex:none;font-size:11.5px;color:var(--ink-3)}
.cr button.cr-file:hover{border-color:var(--sign);color:var(--sign)}

/* The message box: formatting buttons, the paperclip and files waiting to go */
.cr-full .cr-compose{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;column-gap:10px}
.cr-full .cr-compose>*{grid-column:1/-1}
.cr-full .cr-compose>.cr-modes{grid-column:1;justify-self:start}
.cr-full .cr-compose>.cr-tools{grid-column:2;justify-self:end;margin-bottom:8px}
.cr-tools{display:flex;align-items:center;gap:2px}
.cr .cr-tool{display:inline-grid;place-items:center;width:30px;height:30px;min-height:0;padding:0;border:0;border-radius:8px;background:transparent;box-shadow:none;font:700 14px var(--ui);color:var(--ink-2)}
.cr .cr-tool:hover:not(:disabled){background:var(--sheet-2);color:var(--ink)}
.cr .cr-tool:disabled{opacity:.45}
.cr .cr-tool.cr-s{font-weight:600;text-decoration:line-through}
.cr-tools-gap{width:1px;height:16px;margin:0 6px;background:var(--rule)}
.cr-mini .cr-box{padding-left:6px}
.cr-mini .cr-box .cr-clip{align-self:flex-end;margin-bottom:3px;flex:none}
.cr-tray{display:flex;flex-wrap:wrap;gap:6px;margin:8px 4px 0}
.cr-chip{display:inline-flex;align-items:center;gap:4px;max-width:100%;padding:3px 4px 3px 10px;border-radius:999px;background:var(--sheet-2);font-size:12.5px;color:var(--ink-2)}
.cr-chip span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cr-chip.is-busy{padding-right:10px;color:var(--ink-3)}
.cr .cr-chip-x{display:inline-grid;place-items:center;width:20px;height:20px;min-height:0;padding:0;border:0;border-radius:50%;background:transparent;box-shadow:none;font-size:15px;line-height:1;color:var(--ink-3)}
.cr .cr-chip-x:hover{background:var(--rule);color:var(--ink)}

/* Chats or Overview */
.lc-top-main{display:flex;align-items:center;flex-wrap:wrap;gap:10px 18px}
.lc-views{display:inline-flex;gap:2px;padding:3px;border-radius:999px;background:var(--sheet-2)}
.chat-console .lc-views button{min-height:0;padding:5px 14px;border:0;border-radius:999px;background:transparent;box-shadow:none;font:500 13px var(--ui);color:var(--ink-2)}
.chat-console .lc-views button[aria-pressed=true]{background:var(--sheet);color:var(--ink);font-weight:600;box-shadow:0 1px 2px rgba(0,0,0,.08)}
.lc-grid[hidden],.lc-over[hidden]{display:none}
.lc-over{flex:1;min-height:0;overflow-y:auto;display:grid;align-content:start;gap:16px;padding:0 28px 24px}
/* One strip of numbers, not six separate boxes; the waiting count leads. */
.lc-kpis{display:grid;grid-template-columns:1.25fr repeat(5,minmax(0,1fr));border:1px solid var(--rule);border-radius:18px;background:var(--sheet);overflow:hidden}
.chat-console .lc-kpi{display:grid;align-content:start;gap:2px;min-height:0;padding:16px 18px;border:0;border-left:1px solid var(--rule-soft);border-radius:0;background:transparent;box-shadow:none;text-align:left;font:inherit;color:var(--ink)}
.chat-console .lc-kpi:first-child{border-left:0}
.chat-console .lc-kpi:not(:disabled):hover{background:var(--sheet-2)}
.chat-console .lc-kpi:disabled{opacity:1;cursor:default}
.lc-kpi b{font:700 26px/1.1 var(--ui);letter-spacing:-.02em;font-variant-numeric:tabular-nums}
.lc-kpi:first-child b{font-size:34px}
.lc-kpi span{font-size:13px;font-weight:600}
.lc-kpi small{font-size:12px;color:var(--ink-3)}
.chat-console .lc-kpi.is-hot{background:var(--pend-wash,#fff6dc)}
.lc-kpi.is-hot b{color:var(--pend)}
.lc-history{border:1px solid var(--rule);border-radius:18px;background:var(--sheet);overflow:hidden}
.lc-history>header{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px 16px;padding:14px 18px;border-bottom:1px solid var(--rule-soft)}
.lc-history h2{margin:0;font:650 16px var(--ui);letter-spacing:-.01em}
.lc-history-tools{display:flex;align-items:center;gap:8px;flex:1;justify-content:flex-end;min-width:0}
.lc-history-tools .lc-kb-search{flex:0 1 360px}
.lc-history-tools select{min-width:0;width:auto}
.lc-history-scroll{overflow-x:auto}
.lc-table{width:100%;border-collapse:collapse;font-size:13.5px}
.lc-table th{padding:9px 14px;border-bottom:1px solid var(--rule);text-align:left;font:600 12px var(--ui);color:var(--ink-3);white-space:nowrap}
.lc-table td{padding:10px 14px;border-bottom:1px solid var(--rule-soft);vertical-align:top;color:var(--ink-2)}
.lc-table tbody tr:last-child td{border-bottom:0}
.lc-table tr.lr{cursor:pointer}
.lc-table tr.lr:hover td{background:var(--sheet-2)}
.lc-table small{display:block;font-size:12px;color:var(--ink-3)}
.lc-h-when{white-space:nowrap}
.lc-h-title{color:var(--ink);overflow-wrap:anywhere}
.chat-console .lc-h-open{min-height:0;padding:0;border:0;background:transparent;box-shadow:none;font:600 13.5px var(--ui);color:var(--ink);text-align:left}
.chat-console .lc-h-open:hover{color:var(--sign);text-decoration:underline}
.lc-h-state{display:inline-block;padding:2px 9px;border-radius:999px;background:var(--sheet-2);font-size:12px;font-weight:600;color:var(--ink-3);white-space:nowrap}
.lc-h-state.is-open{background:var(--sign-wash);color:var(--sign)}
.lc-h-state.is-waiting{background:var(--pend-wash,#fff6dc);color:var(--pend)}
.lc-history-foot{padding:10px 18px 14px}

/* Articles next to the chat */
.lc-facts.lc-kb>div{display:block}
.lc-kb-search{display:flex;align-items:center;gap:8px;padding:0 10px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet);color:var(--ink-3)}
.lc-kb-search:focus-within{border-color:var(--sign);box-shadow:0 0 0 3px color-mix(in srgb,var(--sign) 16%,transparent)}
.lc-kb-search .i{flex:none;width:15px;height:15px}
.chat-console .lc-kb-search input{flex:1;min-width:0;min-height:34px;padding:0;border:0;background:transparent;box-shadow:none;outline:none;font:400 13.5px var(--ui);color:var(--ink)}
.lc-kb-note{margin:10px 0 6px;font-size:12px;font-weight:600;color:var(--ink-3)}
.lc-kb-list{display:grid;gap:10px;margin:10px 0 0;padding:0;list-style:none}
.lc-kb-list li{display:grid;gap:2px;justify-items:start}
.lc-kb-list b{font-size:13.5px;font-weight:600;color:var(--ink);overflow-wrap:anywhere}
.lc-kb-list small{font-size:12px;color:var(--ink-3)}
.lc-kb-list .btn{margin-top:4px}
.lc-kb #lcKbList>.lc-muted{margin-top:10px}

/* Narrower screens: the customer and the articles sit behind one button */
.lc-room-bar{display:none;flex:none;align-items:center;justify-content:space-between;gap:8px;padding:10px 12px 0}
.chat-console .lc-room-bar .btn{margin:0}
.chat-console .btn.lc-more{margin-left:auto}
@media(max-width:1180px){
  .lc-room-bar{display:flex}
  .lc-grid[data-view=list] .lc-room-bar{display:none}
  .lc-grid[data-details=open]{grid-template-rows:auto minmax(0,1fr)}
  .lc-grid[data-details=open] .lc-list{grid-row:1/3}
  .lc-grid[data-details=open] .lc-room-host{display:none}
  .lc-grid[data-details=open] .lc-room{padding-bottom:10px}
  .lc-grid[data-details=open] .lc-details{display:block;grid-column:2}
}
@media(max-width:900px){
  .lc-over{padding:0 10px 10px}
  .lc-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}
  .chat-console .lc-kpi{border-left:0;border-top:1px solid var(--rule-soft)}
  .chat-console .lc-kpi:nth-child(-n+2){border-top:0}
  .chat-console .lc-kpi:nth-child(even){border-left:1px solid var(--rule-soft)}
  .lc-kpi:first-child b{font-size:26px}
  .lc-history-tools{flex:1 1 100%}.lc-history-tools .lc-kb-search{flex:1}
  .lc-table th:nth-child(3),.lc-table td:nth-child(3),.lc-table th:nth-child(5),.lc-table td:nth-child(5){display:none}
  .lc-grid[data-view=list] .lc-room-bar{display:none}
  .lc-grid[data-details=open] .lc-details{grid-column:1}
  .lc-grid[data-details=open] .lc-list{grid-row:auto}
  .chat-console .lc-grid[data-details=open] .lc-room{min-height:0}
  .lc-top{flex-wrap:wrap}
  .lc-ws{flex:1 1 100%}.lc-ws select{flex:1}
  .cr-full .cr-compose>.cr-tools{margin-bottom:6px}
}
.lc-kb-search .i{fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
@media(max-width:700px){
  /* The history reads as a list of chats on a phone: who and status, then the title, then when. */
  .lc-table thead{display:none}
  .lc-table,.lc-table tbody{display:block}
  .lc-table tr.lr{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2px 10px;padding:12px 14px;border-bottom:1px solid var(--rule-soft)}
  .lc-table tbody tr.lr:last-child{border-bottom:0}
  .lc-table tr.lr td{display:block;padding:0;border:0}
  .lc-table tr.lr td:nth-child(2){grid-column:1;grid-row:1}
  .lc-table tr.lr td:nth-child(6){grid-column:2;grid-row:1}
  .lc-table tr.lr td:nth-child(4){grid-column:1/-1;grid-row:2}
  .lc-table tr.lr td:nth-child(1){grid-column:1/-1;grid-row:3;font-size:12px;color:var(--ink-3)}
  .lc-table tr.lr td:nth-child(2) small,.lc-table tr.lr td:nth-child(4) small{display:inline;margin-left:6px}
  .lc-history-tools select{flex:none;min-width:118px}
}
@media(max-width:560px){
  .cr-full .cr-compose>.cr-modes{grid-column:1/-1}
  .cr-full .cr-compose>.cr-tools{grid-column:1/-1;justify-self:start;margin:0 0 6px}
}
.lc-history-tools .lc-kb-search{min-width:0}
@media(max-width:700px){
  .lc-table tr.lr td:nth-child(3){display:none}
  .lc-table tr.lr td:nth-child(1){grid-column:1}
  .lc-table tr.lr td:nth-child(5){grid-column:2;grid-row:3;font-size:12px;color:var(--ink-3);text-align:right}
}

/* ==========================================================================
   One date-range choice, a tighter Reports form, notifications panel
   2026-11-15
   ========================================================================== */
/* Custom dates: a start and an end beside the list, in Dashboards and Reports */
.dr-error{flex:1 1 100%;margin:0;font-size:12.5px;color:var(--a1)}
.dsh .fbar .dr-date input[type=date]{box-sizing:border-box;height:31px;min-height:0;padding:0 8px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);font:500 13px var(--ui);color:var(--ink)}
.dsh .fbar .fnote{max-width:340px}

/* Reports: the form is as wide as its fields, and the closed form says Expand */
#appShell .report-query .report-controls{grid-template-columns:minmax(160px,220px) minmax(200px,280px) minmax(150px,190px) auto;justify-content:start;align-items:end;gap:14px}
#appShell .report-query .report-controls:has(.dr-date){grid-template-columns:minmax(160px,220px) minmax(200px,280px) minmax(150px,190px) repeat(2,minmax(140px,170px)) auto}
#appShell .report-query .report-controls .dr-error{grid-column:1/-1}
#appShell .report-query>summary::after{display:none}
#appShell .report-query>summary small{font-size:12px}
.report-toggle{flex:none;font:600 12.5px var(--ui);color:var(--sign)}
.report-query[open] .when-closed,.report-query:not([open]) .when-open{display:none}
#appShell .report-query>summary:hover .report-toggle{text-decoration:underline}
@media(max-width:1200px){#appShell .report-query .report-controls,#appShell .report-query .report-controls:has(.dr-date){grid-template-columns:repeat(2,minmax(0,1fr));justify-content:stretch}}
@media(max-width:760px){#appShell .report-query>summary .report-toggle{margin-left:auto}#appShell .report-query .report-controls,#appShell .report-query .report-controls:has(.dr-date){grid-template-columns:minmax(0,1fr)}}

/* Notifications panel: the close button and the actions stay in reach while the middle scrolls */
.sound-panel{width:min(560px,calc(100vw - 24px));padding:0 26px}
.sound-panel .sound-head{position:sticky;top:0;z-index:1;display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 -26px 6px;padding:16px 16px 12px 26px;border-bottom:1px solid var(--rule-soft);background:var(--sheet)}
.sound-panel .sound-head h2{margin:0;font-size:20px;letter-spacing:-.01em}
.sound-panel .sound-x{flex:none;width:44px;height:44px;min-height:44px;padding:0;border-radius:12px;font-size:22px;line-height:1}
.sound-panel #soundStatus{flex:1 1 100%;margin:0 0 4px;font-size:13px;line-height:1.5;color:var(--ink-2)}
.sound-panel #soundStatus:empty{display:none}
.sound-actions{position:sticky;bottom:0;display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:16px -26px 0;padding:12px 26px 16px;border-top:1px solid var(--rule-soft);background:var(--sheet)}
.sound-gap{flex:1}
.sound-actions button{white-space:nowrap}
@media(max-width:600px){
  .sound-panel{max-height:calc(100dvh - 16px);padding:0 16px}
  .sound-panel .sound-head{margin:0 -16px 6px;padding:10px 8px 10px 16px}
  .sound-actions{margin:14px -16px 0;padding:10px 16px 14px}
  .sound-gap{display:none}
  .sound-actions .preview-primary{flex:1}
}

/* ==========================================================================
   Queue form, 2026-11-15
   Anyone's own queue, and the filter of a shared one, in plain choices.
   ========================================================================== */
dialog.qe{box-sizing:border-box;width:min(620px,calc(100vw - 24px));max-height:calc(100dvh - 32px);padding:0;border:1px solid var(--rule);border-radius:18px;background:var(--sheet);color:var(--ink);font:14px var(--ui);box-shadow:0 28px 100px rgba(17,26,52,.32);overflow:hidden}
dialog.qe::backdrop{background:rgba(16,26,51,.5);backdrop-filter:blur(4px)}
.qe-form{display:flex;flex-direction:column;max-height:calc(100dvh - 34px);margin:0}
.qe-head{flex:none;display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:18px 16px 14px 24px;border-bottom:1px solid var(--rule-soft)}
.qe-head h2{margin:0;font:650 19px var(--ui);letter-spacing:-.01em}
.qe-head p{margin:4px 0 0;font-size:13px;line-height:1.5;color:var(--ink-3)}
dialog.qe .qe-x{flex:none;width:44px;height:44px;min-height:44px;padding:0;border:1px solid var(--rule);border-radius:12px;background:var(--sheet-2);box-shadow:none;font-size:22px;line-height:1;color:var(--ink)}
.qe-body{flex:1;min-height:0;overflow-y:auto;display:grid;gap:16px;padding:18px 24px}
.qe-field{display:grid;gap:6px;min-width:0;font:600 12px var(--ui);color:var(--ink-3)}
dialog.qe .qe-field :is(input,select){box-sizing:border-box;width:100%;min-height:38px;padding:0 11px;border:1px solid var(--rule);border-radius:9px;background:var(--sheet);box-shadow:none;font:400 14px var(--ui);color:var(--ink)}
.qe-set{display:grid;gap:12px;min-width:0;margin:0;padding:14px 16px 16px;border:1px solid var(--rule);border-radius:12px}
.qe-set legend{padding:0 6px;font:650 13px var(--ui);color:var(--ink)}
.qe-match{display:flex;flex-wrap:wrap;gap:6px 18px;font-size:13.5px;color:var(--ink-2)}
.qe-match label,.qe-check{display:inline-flex;align-items:center;gap:6px;cursor:pointer}
.qe-row{display:grid;grid-template-columns:76px minmax(0,1fr);gap:10px;align-items:start}
.qe-label{padding-top:5px;font:600 12px var(--ui);color:var(--ink-3)}
.qe-checks{display:flex;flex-wrap:wrap;gap:6px}
.qe-check{padding:4px 11px;border:1px solid var(--rule);border-radius:999px;font-size:13px;color:var(--ink-2);background:var(--sheet)}
.qe-check:has(input:checked){border-color:var(--sign);background:var(--sign-wash);color:var(--sign);font-weight:600}
.qe-check input{width:14px;height:14px;margin:0}
.qe-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.qe-note,.qe-kept{margin:0;font-size:12.5px;line-height:1.5;color:var(--ink-3)}
.qe-kept{padding:9px 11px;border-radius:9px;background:var(--sheet-2);color:var(--ink-2)}
.qe-error{margin:0;font-size:13px;color:var(--a1)}
.qe-error:empty{display:none}
.qe-foot{flex:none;display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:12px 24px 16px;border-top:1px solid var(--rule-soft);background:var(--sheet)}
.qe-gap{flex:1}
dialog.qe .qe-delete{color:var(--a1)}
#appShell .gx .vhead .vhead-link{padding:0;border:0;background:none;box-shadow:none;min-height:0;font:inherit;font-weight:600;color:var(--sign);cursor:pointer}
#appShell .gx .vhead .vhead-link:hover{text-decoration:underline}
@media(max-width:600px){
  .qe-head{padding:12px 10px 10px 16px}.qe-body{padding:14px 16px}.qe-foot{padding:10px 16px 14px}
  .qe-row{grid-template-columns:minmax(0,1fr);gap:4px}.qe-label{padding:0}
  .qe-grid{grid-template-columns:minmax(0,1fr)}
  .qe-gap{display:none}.qe-foot .btn.sign{flex:1}
}
dialog.qe .qe-foot button{min-height:38px;padding:0 16px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet);box-shadow:none;font:600 13.5px var(--ui);color:var(--ink);cursor:pointer}
dialog.qe .qe-foot button:hover{border-color:color-mix(in srgb,var(--sign) 45%,var(--rule))}
dialog.qe .qe-foot button.sign{border-color:var(--sign);background:var(--sign);color:var(--sign-ink,#fff)}
dialog.qe .qe-foot button.qe-delete{border-color:transparent;background:transparent;color:var(--a1)}
dialog.qe .qe-foot button.qe-delete:hover{background:color-mix(in srgb,var(--a1) 8%,transparent)}
dialog.qe .qe-foot button:disabled{opacity:.55;cursor:default}
dialog.qe :is(button,input,select):focus-visible{outline:2px solid var(--sign);outline-offset:2px}

/* Settings: a row of fields with its button lines up along the bottom (holidays, 2026-11-15) */
.stg .settings-page-actions{align-items:flex-end}
#appShell .stg .settings-page-actions>label{margin:0}
#appShell .stg .settings-page-actions:has(>label)>.btn{min-height:42px}

/* Days off, one row each, and the public holiday checklist (2026-11-16) */
.stg .days-off{display:grid;gap:14px;margin:14px 0 22px}
.stg .days-off .setup-table{margin:0}
#appShell .stg .days-off .setup-table td{padding:6px 16px}
#appShell .stg .days-off .settings-page-actions{margin:0}
.stg .days-off .setup-table td:first-child{white-space:nowrap;font-variant-numeric:tabular-nums}
.stg .days-off .setup-table td:last-child{width:1%;text-align:right}
#appShell .stg .days-off .setup-table input{width:100%;min-width:180px;margin:0;min-height:34px;padding:5px 10px;background:transparent;border-color:transparent}
#appShell .stg .days-off .setup-table input:is(:hover,:focus){background:var(--sheet);border-color:var(--rule)}
#appShell .stg .days-off .setup-table .btn{min-height:32px;padding:4px 10px}
.stg .days-off-empty,.stg .days-off-count{margin:0;color:var(--ink-2);font-size:13px}
.stg .days-off-offer{display:grid;gap:8px;margin:0;padding:16px;border:1px solid var(--rule);border-radius:12px;background:var(--sheet)}
.stg .days-off-offer legend{padding:0 6px;font-weight:600}
#appShell .stg .days-off-offer label{display:grid;grid-template-columns:auto 150px 1fr auto;align-items:center;gap:10px;margin:0;font-size:13px}
.stg .days-off-offer label span{color:var(--ink-2);font-variant-numeric:tabular-nums}
.stg .days-off-offer small{color:var(--ink-3)}
.stg .days-off .sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.stg select.zone-picker{max-width:100%}
@media(max-width:600px){#appShell .stg .days-off-offer label{grid-template-columns:auto 1fr}.stg .days-off-offer label b{grid-column:2}}

/* ===================================================================   Ticket list extras, 2026-11-15: chosen columns, suggested articles
   ========================================================================== */
.col-list{display:grid;gap:6px;margin:0;padding:0;list-style:none}
.col-row{display:flex;align-items:center;gap:10px;padding:6px 8px;border:1px solid var(--rule-soft);border-radius:10px}
.col-row small{font-size:12px;color:var(--ink-3)}
.col-move{display:inline-flex;gap:4px;margin-left:auto}
dialog.qe .col-move button{display:inline-grid;place-items:center;width:32px;height:32px;min-height:0;padding:0;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);box-shadow:none;color:var(--ink-2);cursor:pointer}
dialog.qe .col-move button:disabled{opacity:.35;cursor:default}
#appShell .gx .col-edit{flex:none}
.kn .kn-suggest{margin-top:10px}
.kn .kn-sugg{display:grid;gap:10px;margin:0;padding:0;list-style:none}
.kn .kn-sugg li{display:grid;gap:2px;justify-items:start}
.kn .kn-sugg b{font-size:13px;font-weight:600;overflow-wrap:anywhere}
.kn .kn-sugg small{font-size:12px;color:var(--ink-3)}
.kn .kn-sugg .btn{margin-top:4px}
   Knowledge overview, 2026-11-15
   Panels that look like what they are, drafts written by AI, working lists,
   and section colours chosen in Settings.
   ========================================================================== */
/* A colour chosen in Settings wins over the built-in section colours, in light and dark. */
#kView[data-custom-color]{--sign-ink:#fff}
#appShell .kn .knowledge-panel h2{display:flex;align-items:center;gap:8px}
.kp-count{display:inline-grid;place-items:center;min-width:22px;height:22px;padding:0 7px;border-radius:999px;background:var(--sheet-2);font:600 12px var(--ui);color:var(--ink-2)}
.kp-note{margin:0 0 10px;font-size:12.5px;line-height:1.5;color:var(--ink-3)}
/* Needs someone: a warm edge and its count */
#appShell .kn .knowledge-panel.is-alert{border-left:3px solid var(--pend);background:color-mix(in srgb,var(--pend-wash,#fff6dc) 55%,var(--sheet))}
#appShell .kn .knowledge-panel.is-alert .kp-count{background:var(--pend);color:#fff}
/* A ranking: numbered, with a bar for its size */
#appShell .kn .knowledge-panel.is-rank ol{counter-reset:rank}
#appShell .kn .knowledge-panel.is-rank li{position:relative;counter-increment:rank;padding-left:26px;padding-bottom:10px}
#appShell .kn .knowledge-panel.is-rank li::before{content:counter(rank);position:absolute;left:0;top:1px;font:600 12px var(--ui);color:var(--ink-3);font-variant-numeric:tabular-nums}
.kp-bar{position:absolute;left:26px;right:0;bottom:3px;height:3px;border-radius:2px;background:var(--rule-soft);overflow:hidden}
.kp-bar>i{display:block;height:100%;border-radius:2px;background:var(--sign)}
/* Written by AI: marked as its own thing, across the full width */
#appShell .kn .knowledge-panel.is-ai{grid-column:1/-1;border-style:dashed;border-color:color-mix(in srgb,var(--sign) 45%,var(--rule));background:var(--sign-wash)}
#appShell .kn .knowledge-panel.is-ai .kp-count{background:var(--sign);color:var(--sign-ink,#fff)}
/* Searches without answers: topics as chips, not another list of rows */
#appShell .kn .knowledge-panel.is-gaps ul{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 10px;padding:0;list-style:none}
#appShell .kn .knowledge-panel.is-gaps li{display:inline-flex;align-items:baseline;gap:8px;padding:6px 12px;border:1px solid var(--rule);border-radius:999px;background:var(--sheet)}
#appShell .kn .knowledge-panel.is-gaps li b{font-size:12px;font-weight:500;color:var(--ink-3)}

/* The working list a number opens */
.kw .kw-back{margin-bottom:12px}
.kw-bar{display:flex;flex-wrap:wrap;align-items:center;gap:10px 14px;margin:14px 0}
.kw-search{flex:0 1 340px}
#appShell .kn .kw-search input{box-sizing:border-box;width:100%;min-height:38px;padding:0 12px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet);font:400 14px var(--ui);color:var(--ink)}
.kw-count{font-size:12.5px;color:var(--ink-3)}
.kw-bulk{display:inline-flex;flex-wrap:wrap;align-items:center;gap:8px;margin-left:auto;padding:6px 10px;border-radius:12px;background:var(--sign-wash)}
.kw-bulk[hidden]{display:none}
.kw-bulk b{font-size:13px;color:var(--sign)}
.kw-split{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:16px;align-items:start}
.kw-split:not(:has(.kw-peek)){grid-template-columns:minmax(0,1fr)}
.kw-list{border:1px solid var(--rule);border-radius:14px;background:var(--sheet);overflow-x:auto}
.kw-table{width:100%;border-collapse:collapse;font-size:13.5px}
.kw-table th{padding:10px 14px;border-bottom:1px solid var(--rule);text-align:left;font:600 12px var(--ui);color:var(--ink-3);white-space:nowrap}
.kw-table td{padding:10px 14px;border-bottom:1px solid var(--rule-soft);vertical-align:top;color:var(--ink-2)}
.kw-table tbody tr:last-child td{border-bottom:0}
.kw-table tbody tr:hover td,.kw-table tr.is-picked td{background:var(--sheet-2)}
.kw-table .kw-pick{width:34px}
.kw-acts{display:flex;flex-wrap:wrap;gap:6px;justify-content:flex-end}
.kw-none{margin:0;padding:18px;font-size:13px;color:var(--ink-3)}
.kw-peek{position:sticky;top:12px;display:grid;gap:10px;padding:16px;border:1px solid var(--rule);border-radius:14px;background:var(--sheet)}
.kw-peek h3{margin:0;font:650 15px var(--ui);overflow-wrap:anywhere}
.kw-peek dl{display:grid;gap:6px;margin:0}
.kw-peek dl div{display:flex;justify-content:space-between;gap:12px;font-size:13px}
.kw-peek dt{color:var(--ink-3)}.kw-peek dd{margin:0;text-align:right;overflow-wrap:anywhere}
.kw-excerpt{margin:0;font-size:13px;line-height:1.55;color:var(--ink-2);overflow-wrap:anywhere}
.kw-peek .btn{justify-self:start}
.visually-hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.kn-color input[type=color]{width:44px;height:32px;padding:2px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet)}
@media(max-width:900px){.kw-split{grid-template-columns:minmax(0,1fr)}.kw-peek{display:none}.kw-bulk{margin-left:0}}
#appShell .kn .kw :is(td,dd,dt,.kw-excerpt,.kw-count),#appShell .kn .kw .report-heading p{font-weight:400;letter-spacing:0}
#appShell .kn .kw .kw-table td .knowledge-document-link{font-weight:600}
/* Metric logic in plain language, 2026-11-15 */
.metric-inspector .metric-plain{margin:0 0 18px;display:grid;gap:0;border:1px solid var(--rule);border-radius:10px;overflow:hidden;background:var(--sheet)}
.metric-inspector .metric-plain>div{display:grid;grid-template-columns:180px minmax(0,1fr);gap:16px;padding:12px 16px;border-top:1px solid var(--rule-soft)}
.metric-inspector .metric-plain>div:first-child{border-top:0}
.metric-inspector .metric-plain dt{font:600 13px/1.45 var(--ui);color:var(--ink-2,var(--ink))}
.metric-inspector .metric-plain dd{margin:0;font:400 14px/1.55 var(--ui);color:var(--ink);max-width:68ch}
.metric-inspector .metric-plain>div.is-key{background:var(--sign-wash)}
.metric-inspector .metric-plain>div.is-key dt{color:var(--sign)}
.metric-inspector .metric-technical{border-top:1px solid var(--rule);padding-top:12px}
.metric-inspector .metric-technical>summary{cursor:pointer;font:600 13px/1.4 var(--ui);color:var(--ink-2,var(--ink))}
.metric-inspector .metric-technical>p{font:400 13px/1.5 var(--ui);color:var(--ink-2,var(--ink));margin:8px 0 12px}
@media (max-width:640px){.metric-inspector .metric-plain>div{grid-template-columns:1fr;gap:4px}}

/* Automatic availability settings, 2026-11-15 */
.auto-avail .setup-fields label{display:grid;gap:6px;font:500 13px/1.4 var(--ui);color:var(--ink-2)}
.auto-avail .setup-fields select{min-height:38px;max-width:220px}
.auto-avail .auto-avail-saved{margin-left:12px;font:500 13px/1.4 var(--ui);color:var(--ink-2)}

/* Active work time in Live chat, 2026-11-15 */
.lc-room-bar .lc-time{display:inline-flex;align-items:center;gap:6px;margin-left:auto;font:500 12.5px/1.3 var(--ui);color:var(--ink-3)}
.lc-room-bar .lc-time b{font-weight:500}
.lc-room-bar .lc-time.is-off{display:none}

/* Agent availability report, 2026-11-15 */
.report-document .report-availability td,.report-document .report-availability th{white-space:nowrap}
.report-document .report-availability td:first-child{white-space:normal}
.report-document .report-share{display:inline-block;vertical-align:middle;width:72px;height:6px;margin-right:8px;border-radius:3px;background:var(--rule-soft);overflow:hidden}
.report-document .report-share i{display:block;height:100%;background:var(--sign)}
.report-document .report-availability-off{margin:0 0 18px;padding:12px 16px;border:1px solid var(--rule);border-radius:10px;background:var(--pend-wash);font:400 14px/1.5 var(--ui)}

/* Customer rating in Live chat, 2026-11-15 */
.lc-rating{display:inline-flex;align-items:baseline;gap:1px;padding:2px 9px;border-radius:999px;font:600 12.5px/1.4 var(--ui);white-space:nowrap}
.lc-rating i{font-style:normal;font-weight:500;opacity:.7}
.lc-rating.is-good{background:var(--sign-wash);color:var(--sign)}
.lc-rating.is-bad{background:var(--pend-wash);color:var(--pend)}
.lc-rating-note{display:block;margin-top:4px;max-width:28ch;color:var(--ink-3);font:400 12px/1.4 var(--ui);overflow-wrap:anywhere}
.lc-fact-rating{display:grid;gap:4px;margin-top:8px}

/* Feature requests page, 2026-11-15 */
.fr-page{padding:28px 32px 48px;max-width:1240px;margin:0 auto;font-family:var(--ui);color:var(--ink)}
.fr-page[hidden]{display:none}
.fr-top{display:flex;justify-content:space-between;align-items:flex-end;gap:24px;margin-bottom:22px}
.fr-top h1{margin:0 0 4px;font:600 26px/1.2 var(--ui);letter-spacing:-.01em}
.fr-top p{margin:0;color:var(--ink-2);font-size:14px}
.fr-ws{display:grid;gap:4px;font-size:12.5px;color:var(--ink-3)}
.fr-layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:28px;align-items:start}
.fr-tools{display:flex;flex-wrap:wrap;gap:12px;justify-content:space-between;align-items:center;margin-bottom:14px}
.fr-filters{display:flex;flex-wrap:wrap;gap:6px}
.fr-filters button{display:inline-flex;align-items:center;gap:6px;min-height:32px;padding:0 12px;border:1px solid var(--rule);border-radius:999px;background:var(--sheet);color:var(--ink-2);font:500 13px var(--ui);cursor:pointer}
.fr-filters button i{font-style:normal;color:var(--ink-3);font-size:12px}
.fr-filters button[aria-pressed="true"]{background:var(--sign);border-color:var(--sign);color:var(--sign-ink)}
.fr-filters button[aria-pressed="true"] i{color:inherit;opacity:.8}
.fr-tools input[type=search]{min-height:34px;width:240px;max-width:100%;padding:0 12px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:400 14px var(--ui)}
.fr-card{display:grid;grid-template-columns:72px minmax(0,1fr);gap:18px;padding:18px 20px;border:1px solid var(--rule);border-radius:12px;background:var(--sheet);margin-bottom:12px}
.fr-card.is-pending{border-color:var(--pend);background:var(--pend-wash)}
.fr-votes{display:grid;place-items:center;align-content:center;height:64px;border-radius:10px;background:var(--sheet-2);color:var(--ink-2)}
.fr-votes b{font:600 22px/1 var(--ui);color:var(--ink)}
.fr-votes span{font-size:11.5px}
.fr-main header{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}
.fr-main h3{margin:0;font:600 16px/1.35 var(--ui);overflow-wrap:anywhere}
.fr-states{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}
.fr-state{padding:2px 10px;border-radius:999px;background:var(--sheet-2);color:var(--ink-2);font:600 12px/1.6 var(--ui);white-space:nowrap}
.fr-state[data-stage=planned],.fr-state[data-stage=in_progress]{background:var(--sign-wash);color:var(--sign)}
.fr-state[data-stage=released]{background:var(--sign);color:var(--sign-ink)}
.fr-state.is-review{background:var(--pend);color:#fff}
.fr-state.is-off{color:var(--ink-3)}
.fr-body{margin:8px 0;color:var(--ink);font-size:14px;line-height:1.55;max-width:72ch;white-space:pre-wrap;overflow-wrap:anywhere}
.fr-meta{margin:0;color:var(--ink-3);font-size:12.5px}
.fr-actions{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;margin-top:14px}
.fr-actions label,.fr-reply label,.fr-access label{display:grid;gap:4px;font-size:12.5px;color:var(--ink-3)}
.fr-actions select,.fr-actions input,.fr-ws select,.fr-access select{min-height:34px;padding:0 10px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:400 14px var(--ui)}
.fr-actions input{width:130px}
.fr-reply{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:end;margin-top:12px}
.fr-reply textarea{width:100%;padding:8px 10px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:400 14px/1.45 var(--ui);resize:vertical}
.fr-side section{padding:18px 20px;border:1px solid var(--rule);border-radius:12px;background:var(--sheet);margin-bottom:14px}
.fr-side h2{margin:0 0 10px;font:600 14px var(--ui)}
.fr-board{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:8px;align-items:center;padding:8px 0;border-top:1px solid var(--rule-soft)}
.fr-board:first-of-type{border-top:0}
.fr-board span{display:grid;gap:2px;min-width:0}
.fr-board code{font-size:12px;color:var(--ink-3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.fr-hint,.fr-none{margin:10px 0 0;color:var(--ink-3);font-size:13px;line-height:1.5}
.fr-note{margin:0 0 12px;padding:8px 12px;border-radius:8px;background:var(--sign-wash);color:var(--ink);font-size:13.5px}
.fr-error{color:var(--pend)}
@media (max-width:900px){.fr-page{padding:18px 16px 40px}.fr-layout{grid-template-columns:1fr}.fr-top{flex-direction:column;align-items:flex-start}.fr-card{grid-template-columns:56px minmax(0,1fr);gap:12px;padding:14px}.fr-main header{flex-direction:column}.fr-states{justify-content:flex-start}.fr-reply{grid-template-columns:1fr}.fr-tools input[type=search]{width:100%}}

.fr-page .btn{display:inline-flex;align-items:center;justify-content:center;min-height:34px;padding:0 14px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:500 13.5px var(--ui);cursor:pointer;text-decoration:none;white-space:nowrap}
.fr-page .btn:hover{background:var(--sheet-2)}
.fr-page .btn.sign{background:var(--sign);border-color:var(--sign);color:var(--sign-ink)}
.fr-page .btn:disabled{opacity:.55;cursor:default}
=======

/* Email templates settings, 2026-11-15 */
.email-templates .et-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:28px;align-items:start}
.email-templates h3{margin:0 0 6px}
.email-templates label{display:block;margin:14px 0 6px;font:600 13px/1.4 var(--ui);color:var(--ink-2)}
.email-templates textarea{width:100%;padding:10px 12px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:400 14px/1.5 var(--ui);resize:vertical}
.email-templates .et-chips{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-top:14px}
.email-templates .et-chips span{width:100%;font:500 12.5px var(--ui);color:var(--ink-3)}
.email-templates .et-chip{min-height:28px;padding:0 10px;border:1px solid var(--rule);border-radius:999px;background:var(--sheet-2);color:var(--ink);font:500 12.5px var(--ui);cursor:pointer}
.email-templates .et-chip:hover{border-color:var(--sign);color:var(--sign)}
.email-templates .et-hint{color:var(--ink-3);font-size:13px;margin:14px 0}
.email-templates .et-actions{display:flex;align-items:center;gap:12px}
.email-templates .et-actions span{font:500 13px var(--ui);color:var(--ink-2)}
.email-templates .et-preview pre{margin:10px 0 0;padding:16px 18px;border:1px solid var(--rule);border-radius:10px;background:var(--sheet-2);color:var(--ink);font:400 14px/1.6 var(--ui);white-space:pre-wrap;overflow-wrap:anywhere;min-height:160px}
.email-templates .et-preview pre.is-bad{border-color:var(--pend);background:var(--pend-wash)}
@media (max-width:900px){.email-templates .et-grid{grid-template-columns:1fr}}

/* Phone-width pass, 2026-11-15: the Knowledge workspace picker no longer runs off the right edge. */
@media (max-width:640px){#appShell #kTop .wsel{flex:1 1 100%;min-width:0}#appShell #kTop .wsel select{min-width:0;width:100%;max-width:100%}}

/* Get started, 2026-11-15 */
.get-started{margin:0 0 22px;padding:22px 24px;border:1px solid var(--rule);border-radius:14px;background:linear-gradient(var(--sign-wash),var(--sheet) 70%);font-family:var(--ui);color:var(--ink)}
.get-started>header{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:16px}
.get-started h2{margin:0 0 4px;font:600 20px/1.25 var(--ui);letter-spacing:-.01em}
.get-started header p{margin:0;color:var(--ink-2);font-size:14px}
.get-started .gs-hide,.get-started .gs-link{border:0;background:none;padding:0;color:var(--ink-3);font:500 13px var(--ui);cursor:pointer;text-decoration:underline;text-underline-offset:3px}
.get-started .gs-link{color:var(--sign)}
.get-started .gs-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.get-started article{display:flex;flex-direction:column;gap:8px;padding:16px;border:1px solid var(--rule);border-radius:12px;background:var(--sheet)}
.get-started article h3{margin:0;font:600 15px/1.3 var(--ui)}
.get-started article p{margin:0;color:var(--ink-2);font-size:13.5px;line-height:1.5}
.get-started article>.btn{align-self:flex-start;margin-top:auto}
.get-started .btn{display:inline-flex;align-items:center;min-height:34px;padding:0 14px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:500 13.5px var(--ui);cursor:pointer}
.get-started .btn.sign{background:var(--sign);border-color:var(--sign);color:var(--sign-ink)}
.get-started .gs-ask{display:grid;gap:8px;margin-top:4px}
.get-started .gs-ask form{display:grid;gap:6px}
.get-started .gs-ask label{font:500 12.5px var(--ui);color:var(--ink-3)}
.get-started .gs-ask form div{display:flex;flex-direction:column;align-items:flex-start;gap:8px}
.get-started article,.get-started .gs-ask,.get-started .gs-ask form{min-width:0}
.get-started .gs-ask input{width:100%}
.get-started .gs-ask .gs-link{justify-self:start;text-align:left}
.get-started .gs-ask input{flex:1;min-width:0;min-height:34px;padding:0 10px;border:1px solid var(--rule);border-radius:8px;background:var(--sheet);color:var(--ink);font:400 14px var(--ui)}
.get-started .gs-note{padding:8px 10px;border-radius:8px;background:var(--sign-wash);color:var(--ink)}
@media (max-width:1100px){.get-started .gs-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:640px){.get-started{padding:16px}.get-started .gs-grid{grid-template-columns:1fr}.get-started .gs-ask form div{flex-direction:column}}

/* Ticket list on a desk screen (2026-11-16): more tickets above the fold, and the last column no longer cut off.
   The table needed 980px but had 938px beside the queue list at 1440px, so "Reply due" was clipped. */
@media (min-width:901px){
  #appShell .gx .queue-heading{padding:16px 28px 10px}
  #appShell .gx .queue-filters{padding-bottom:10px}
  #appShell .gx .queue-toolbar{padding:10px 28px;row-gap:8px}
  #appShell .gx .ticket-table{min-width:900px}
  #appShell .gx .ticket-table tbody td{padding-top:8px;padding-bottom:8px}
  #appShell .gx .ticket-table .col-sort{min-height:38px;padding-top:8px;padding-bottom:8px}
  /* Room moves from the subject (which already shortens) to the last columns, so "Urgent" and "3d 13h overdue" stay whole. */
  #appShell .gx .ticket-table th.col-ticket{width:26%}
  #appShell .gx .ticket-table th.col-org{width:13%}
  #appShell .gx .ticket-table th.col-priority{width:10%}
  #appShell .gx .ticket-table th.col-due{width:14%}
  #appShell .gx .ticket-table .col-priority .acu-sq{white-space:nowrap}
  /* The subject uses the whole cell; Preview appears over its end on hover instead of holding 92px empty on every row. */
  #appShell .gx .ticket-table tbody td.col-ticket{padding-right:16px}
  #appShell .gx .ticket-table .ticket-peek-trigger{background:var(--sheet);box-shadow:-10px 0 8px -2px var(--sheet)}
  #appShell .gx .ticket-table tr:hover .ticket-peek-trigger{background:var(--sign-wash);box-shadow:-10px 0 8px -2px var(--sign-wash)}
}

/* Keep the workspace picker and content-gap actions usable on narrow phones. */
@media (max-width:640px) {
  #appShell #kTop .knowledge-actions .wsel { flex:1 1 100%; width:100%; min-width:0; }
  #appShell #kTop .knowledge-actions .wsel select { flex:1; min-width:0; width:100%; }
  .kw-search-table, .kw-search-table tbody { display:block; }
  .kw-search-table thead { position:absolute; width:1px; height:1px; padding:0; overflow:hidden; clip-path:inset(50%); }
  .kw-search-table tr { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); padding:14px; gap:10px; border-bottom:1px solid var(--rule); }
  .kw-search-table tr:last-child { border-bottom:0; }
  .kw-search-table td { padding:0; border:0; min-width:0; overflow-wrap:anywhere; }
  .kw-search-table td:first-child, .kw-search-table .kw-acts { grid-column:1 / -1; }
  .kw-search-table td[data-label]::before { content:attr(data-label); display:block; font-size:12px; color:var(--muted); }
  .kw-search-table .kw-acts { justify-content:flex-start; }
  .kw-search-table .kw-acts .btn { min-height:44px; }
}

/* The expanded phone chooser must show choices below its toolbar. */
@media screen and (max-width:820px) {
  #appShell .dsh .dlist:not(.off) { height:min(55dvh,440px); max-height:none; overflow-y:auto; }
  #appShell .dsh .dlist .di { min-height:44px; }
}

/* Dashboard cards need room for their title, chart and actions on phones. */
@media screen and (max-width:640px) {
  #appShell .dsh #dshGrid { display:flex; flex-direction:column; gap:14px; }
  #appShell .dsh #dshGrid .tile { flex:none; min-height:300px; padding:16px; }
  #appShell .dsh #dshGrid .th { flex-shrink:0; min-height:32px; }
  #appShell .dsh #dshGrid .tt h4 { white-space:normal; overflow-wrap:anywhere; }
  #appShell .dsh #dshGrid .metric-chart-open { min-height:180px; }
  #appShell .dsh #dshGrid .tile:has(.cnum) { min-height:230px; }
  #appShell .dsh #dshGrid .tile:has(.cnum) .metric-chart-open { min-height:110px; }
  #appShell .dsh #dshGrid .metric-tile-actions { padding:10px 0 0; }
  #appShell .dsh #dshGrid .metric-tile-actions .btn { min-height:44px; }
  #appShell .dsh #dshGrid .th .pb { width:40px; height:40px; margin:-4px -4px 0 0; }
}

/* Ticket list filters beside the queue list (2026-11-16): My tickets, Unassigned and All tickets are already in the
   queue list on the left, so while that list is open the row above the table keeps only what it adds (Overdue,
   Pending, Solved & closed) and sits on the same line as Columns and Sort. Phones, and a collapsed queue list,
   keep every filter. */
@media (min-width:901px){
  #appShell .gx .split:not(.v-off) .queue-filters :is([data-qfilter=all],[data-qfilter=mine],[data-qfilter=unassigned]){display:none}
  #appShell .gx .split:not(.v-off) .queue-refine-content{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;padding:10px 28px;border-top:1px solid var(--rule-soft)}
  #appShell .gx .split:not(.v-off) .queue-refine-content :is(.queue-filters,.queue-toolbar){display:contents}
  #appShell .gx .split:not(.v-off) .queue-toolbar>.queue-search{order:1;flex:1 1 200px}
  #appShell .gx .split:not(.v-off) .queue-toolbar>label.queue-sort:not(:last-child){order:2}
  #appShell .gx .split:not(.v-off) .queue-toolbar>:is(.col-edit,.queue-options,#queueResult){order:3}
  #appShell .gx .split:not(.v-off) .queue-filters>button{order:4;padding:5px 10px;gap:6px;font-size:12.5px}
  #appShell .gx .split:not(.v-off) .queue-toolbar>label.queue-sort:last-child{order:5;margin-left:auto}
}

/* Toggles, 2026-11-18 (issue #265). One on/off setting per row: its text on
   the left, a switch on the right. Used by Settings (St.toggle) and the AI
   agents editor (toggleRow). The switch is a native checkbox with
   role="switch", drawn like the .sw button switch: a 34x20 track in --rule,
   --sign when on, a 16px white thumb.
   This retires the checkbox look for single settings, and the older switch
   classes .fb-switch, .lc-option and .auto-avail-switch; do not bring them
   back. Lists where you pick several items keep checkboxes.
   :not(#_):not(#_) lifts specificity above the app-shell- and .stg-scoped
   label and input rules (polish.css, workspace-ui.css, settings.css) so a
   toggle looks the same on every page, without !important. */
.gd-toggle:not(#_):not(#_){display:flex;align-items:center;justify-content:space-between;gap:16px;box-sizing:border-box;width:100%;max-width:640px;min-height:44px;margin:0;padding:6px 0;border:0;border-radius:0;background:none;box-shadow:none;font:400 13.5px/1.45 var(--ui);color:var(--ink);text-transform:none;letter-spacing:normal;cursor:pointer}
.gd-toggle:not(#_):not(#_)>.gd-toggle-text{display:block;flex:1 1 auto;min-width:0;overflow-wrap:anywhere}
.gd-toggle:not(#_):not(#_) .gd-toggle-text b{display:block;font-weight:600;font-size:inherit;color:var(--ink)}
.gd-toggle:not(#_):not(#_) .gd-toggle-text small{display:block;margin-top:2px;font:400 12.5px/1.4 var(--ui);color:var(--ink-3)}
.gd-toggle:not(#_):not(#_):has(.gd-switch:disabled){cursor:not-allowed;color:var(--ink-3)}
/* Compact: the switch beside a short state word ("On"/"Off", "Required") in a header or a row of fields. */
.gd-toggle.is-compact:not(#_):not(#_){display:inline-flex;justify-content:flex-start;gap:8px;width:auto;max-width:none;min-height:0;padding:0;flex:none;font-weight:600;font-size:12.5px;white-space:nowrap}
.gd-switch:not(#_):not(#_){appearance:none;-webkit-appearance:none;position:relative;flex:none;box-sizing:border-box;width:34px;height:20px;min-width:34px;min-height:0;max-width:none;margin:0;padding:0;border:0;border-radius:999px;background:var(--rule);box-shadow:none;cursor:pointer;vertical-align:middle;transition:background var(--gd-fast,.15s)}
.gd-switch:not(#_):not(#_)::before{content:none;display:none}
.gd-switch:not(#_):not(#_)::after{content:"";position:absolute;inset:auto;top:2px;left:2px;width:16px;height:16px;border:0;border-radius:50%;background:#fff;box-shadow:0 1px 2px #0003;opacity:1;transform:none;transition:transform var(--gd-fast,.15s)}
.gd-switch:not(#_):not(#_):checked{background:var(--sign)}
.gd-switch:not(#_):not(#_):checked::after{transform:translateX(14px)}
.gd-switch:not(#_):not(#_):disabled{opacity:.45;cursor:not-allowed}
.gd-switch:not(#_):not(#_):focus-visible{outline:2px solid var(--sign);outline-offset:2px}
@media (prefers-reduced-motion:reduce){.gd-switch:not(#_):not(#_),.gd-switch:not(#_):not(#_)::after{transition:none}}
/* Automatic availability: the page's one main switch keeps its heading weight. */
.auto-avail .auto-avail-toggle:not(#_):not(#_){font-weight:600;font-size:15px}
