
/* EVA message architecture: Zulip-inspired navigation, Octo-native subzones. */
body.eva-message-hierarchy-ready .eva-msg .ch-list {
  width: 336px;
  min-width: 336px;
  border-right: 1px solid #dfe3e8;
  background: #f6f7f8;
}

/* The project is a message-area view, so the route and conversation rail stay intact. */
body.eva-message-hierarchy-ready .eva-msg .ch-main {
  position: relative;
}

body.eva-message-hierarchy-ready .eva-msg .ch-layout {
  position: relative;
}

body.eva-message-hierarchy-ready .eva-msg .eva-inline-project-panel {
  position: absolute;
  z-index: 5;
  top: 0;
  right: 0;
  bottom: 0;
  left: var(--eva-conversation-rail-current, 260px);
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
  background: #fff;
}

body.eva-message-hierarchy-ready .eva-msg .eva-inline-project-panel__body,
body.eva-message-hierarchy-ready .eva-msg .eva-inline-project-panel__body .collab-frame {
  min-height: 0;
  flex: 1;
}

/* SpaceFrame is also used as a first-level project page.  In the message
   surface it must be a normal child of the right-hand pane, never a viewport
   layer: otherwise its page styles paint over the navigation. */
body.eva-message-hierarchy-ready .eva-msg .eva-inline-project-panel__body {
  position: relative;
  z-index: 1;
  display: flex;
  min-width: 0;
  overflow: hidden;
}

body.eva-message-hierarchy-ready .eva-msg .eva-inline-project-panel__body > .collab-frame {
  position: relative !important;
  inset: auto !important;
  z-index: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 100% !important;
  min-width: 0;
  overflow: hidden;
}

/* The message rail already provides group navigation. Avoid repeating the
   project's group-chat tab while the project is embedded beside that rail. */
body.eva-message-hierarchy-ready
  .eva-msg
  .eva-inline-project-panel
  .collab-tabs__list
  .collab-tab:nth-child(2) {
  display: none;
}


body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar {
  display: none;
  margin: 0 10px 8px;
  padding: 0;
  border: 0;
}

body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__container {
  gap: 4px;
  padding: 0;
  background: transparent;
}

body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__btn {
  min-width: 0;
  min-height: 34px;
  justify-content: flex-start;
  padding: 0 10px;
  border-radius: 7px;
  color: #3f4a52;
}

body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__btn:hover {
  background: #e8ebed;
}

body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__btn--active {
  background: #dde7ec;
  color: #183b4a;
  font-weight: 600;
}

body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__btn--active::after {
  display: none;
}

body.eva-message-hierarchy-ready .eva-msg .ch-list__scroll {
  padding: 3px 8px 18px;
  scrollbar-color: #c7cdd2 transparent;
}

/* 项目 IM 的唯一结构：大群 → 可选子区。 */
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-channel-surface="project"]
  .eva-msg
  .ch-list {
  width: 320px;
  min-width: 320px;
}


body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-channel-surface="project"]
  .eva-msg
  .ch-list__scroll {
  padding: 5px 10px 18px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-channel-surface="project"]
  .eva-msg
  .wk-conv-compact-item:not(.wk-conv-compact-item--thread) {
  min-height: 38px;
  margin-top: 8px;
  padding: 6px 8px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-channel-surface="project"]
  .eva-msg
  .wk-conv-compact-item--thread {
  min-height: 28px;
  padding: 4px 8px 4px 38px;
}

body.eva-message-hierarchy-ready .wk-category-section {
  margin: 0 0 7px;
}

body.eva-message-hierarchy-ready .eva-msg .wk-category-header {
  width: 100%;
  min-height: 32px;
  margin: 0;
  padding: 0 8px;
  border-radius: 7px;
  color: #4c5962;
  transition: background-color 120ms ease, color 120ms ease;
}

body.eva-message-hierarchy-ready .eva-msg .wk-category-header:hover {
  background: #e8ebed;
  color: #26343d;
}

body.eva-message-hierarchy-ready .eva-msg .wk-category-header__name {
  min-width: 0;
  font-size: 13px;
  font-weight: 600;
}

body.eva-message-hierarchy-ready .eva-msg .wk-category-header__arrow {
  color: #66717a;
}

body.eva-message-hierarchy-ready .eva-msg .wk-conv-compact-entity-avatar,
body.eva-message-hierarchy-ready .eva-msg .eva-entity-avatar {
  display: block;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
}

body.eva-message-hierarchy-ready .eva-msg .eva-dm-scope,
body.eva-message-hierarchy-ready .eva-msg .eva-org-scope {
  margin-top: 10px;
  padding-top: 5px;
  border-top: 1px solid #e1e4e7;
}

body.eva-message-hierarchy-ready .eva-msg .eva-dm-scope .wk-conv-compact-item,
body.eva-message-hierarchy-ready .eva-msg .eva-org-scope .wk-conv-compact-item {
  border-radius: 7px;
}

body.eva-message-hierarchy-ready .eva-msg .wk-conv-compact-item--selected {
  background: #f0f1f2;
}

body.eva-message-hierarchy-ready .eva-msg .ch-cat-gear:not(.eva-message-invite) {
  display: none;
}

body.eva-message-hierarchy-ready .ch-head__scope {
  border: 1px solid #d8e2e7;
  border-radius: 6px;
  background: #eef3f5;
  color: #49616e;
  font-weight: 500;
}

/* Ported from Octo-Web's group-to-thread breadcrumb. */
body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel,
body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-avatar,
body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-info {
  display: flex;
  align-items: center;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel {
  gap: var(--wk-sp-2);
  min-width: 0;
  overflow: hidden;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-avatar {
  justify-content: center;
  flex-shrink: 0;
  line-height: 0;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-info {
  min-width: 0;
  overflow: hidden;
}
body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-info:has(.eva-chat-project-context) {
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}


body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-info-name {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow: hidden;
  flex-wrap: nowrap;
  min-width: 0;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-info-name--thread {
  gap: var(--wk-sp-1-5);
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-parent-group {
  display: block;
  color: var(--wk-text-tertiary, #9498a8);
  font-size: 14px;
  font-weight: 400;
  cursor: pointer;
  transition: color 150ms;
  white-space: nowrap;
  flex-shrink: 0;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-parent-group:hover {
  color: var(--wk-text-secondary, #5c6070);
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-separator {
  display: inline-flex;
  width: 14px;
  height: 14px;
  align-items: center;
  justify-content: center;
  color: var(--wk-text-tertiary, #9498a8);
  flex-shrink: 0;
  transform: translateY(1px);
  user-select: none;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-thread-name {
  display: block;
  color: var(--wk-text-primary, #1a1c24);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex-shrink: 1;
}

body.eva-message-hierarchy-ready .ch-head .wk-chat-conversation-header-channel-thread-icon {
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--wk-icon-muted);
  flex-shrink: 0;
  background: none;
  border-radius: 0;
}

body.eva-message-hierarchy-ready .eva-msg .wk-category-header:focus-visible,
body.eva-message-hierarchy-ready .eva-msg .wk-conv-compact-item:focus-visible,
body.eva-message-hierarchy-ready .eva-msg .wk-sidebar-tabbar__btn:focus-visible {
  outline: 2px solid #4d7f93;
  outline-offset: 1px;
}

@media (prefers-reduced-motion: reduce) {
  body.eva-message-hierarchy-ready .eva-msg .wk-category-header,
  body.eva-message-hierarchy-ready .eva-msg .wk-conv-compact-item {
    transition: none;
  }
}

/* One source of truth for Space identity across activity, messages and Space pages. */
body.eva-message-hierarchy-ready .eva-space-card-foundation {
  --eva-space-card-surface: #f1f3f5;
  --eva-space-card-accent: #59636d;
  --eva-space-card-border: #e2e5e8;
  --eva-space-card-notice-surface: #e8ebee;
  --eva-space-card-notice-text: #4f5b64;
}

body.eva-message-hierarchy-ready .eva-space-card-foundation[data-eva-space-tone="product"] {
  --eva-space-card-surface: #edf2f7;
  --eva-space-card-accent: #465f8e;
  --eva-space-card-border: #dbe4ee;
  --eva-space-card-notice-surface: #dfe8f1;
  --eva-space-card-notice-text: #465f8e;
}

body.eva-message-hierarchy-ready .eva-space-card-foundation[data-eva-space-tone="delivery"] {
  --eva-space-card-surface: #edf6f1;
  --eva-space-card-accent: #356d5d;
  --eva-space-card-border: #d8e9e1;
  --eva-space-card-notice-surface: #deeee6;
  --eva-space-card-notice-text: #356d5d;
}

body.eva-message-hierarchy-ready .eva-space-card-foundation[data-eva-space-tone="drive"] {
  --eva-space-card-surface: #f1eff9;
  --eva-space-card-accent: #62588a;
  --eva-space-card-border: #e2def0;
  --eva-space-card-notice-surface: #e5e1f2;
  --eva-space-card-notice-text: #62588a;
}

/* Real Semi Card establishes each collaboration space as a strong ownership block. */
.eva-msg .eva-space-card {
  margin: 8px 0 16px;
  border-color: var(--eva-space-card-border);
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
  overflow: hidden;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card > .semi-card-header {
  min-height: 44px;
  padding: 6px 12px;
  border-bottom-color: var(--eva-space-card-border);
  background-color: var(--eva-space-card-surface);
}

.eva-msg .eva-space-card .semi-card-header-wrapper {
  align-items: center;
}

.eva-msg .eva-space-card .semi-card-header-wrapper-spacing {
  margin-right: 10px;
}

.eva-msg .eva-space-card .semi-card-header-wrapper-title {
  overflow: visible;
}

.eva-msg .eva-space-card .semi-card-header-wrapper-extra {
  font-size: 12px;
  font-weight: 500;
}

.eva-msg .eva-space-card .wk-category-header {
  min-height: 30px;
  padding: 0;
  color: #1f2933;
}

.eva-msg .eva-space-card .wk-category-header:hover {
  background: transparent;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow {
  margin-right: 5px;
  color: #4b5560;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__name {
  overflow: hidden;
  font-size: 14px;
  font-weight: 680;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__name,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow {
  color: var(--eva-space-card-accent);
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-task-button {
  width: 30px;
  min-width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 7px;
  background: rgb(255 255 255 / 58%);
  color: #44515b;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-task-button:hover {
  background: rgb(255 255 255 / 88%);
  color: #1f2933;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-task-button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 1px;
}

.eva-msg .eva-space-card .wk-category-header__badges {
  margin-left: auto;
}

.eva-msg .eva-space-card .semi-tag {
  border-color: transparent;
  background: rgb(255 255 255 / 70%);
  color: #52616b;
}

.eva-msg .eva-space-card .semi-card-body {
  background: #fff;
}

.eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) {
  min-height: 38px;
  margin: 2px 0;
  padding: 7px 8px;
  border-radius: 8px;
}

.eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread):hover {
  background: #f2f4f6;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--selected,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--selected:hover {
  background: #f0f1f2;
  box-shadow: none;
}

.eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) .wk-conv-compact-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
}

/* 群聊名称支持双击收缩／展开子区；右侧用与“我的 AI”相同的折叠方向图标
   表达当前状态，单击图标也可完成同一操作。 */
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) .wk-conv-compact-thread-tag {
  display: none;
}
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-thread-toggle {
  display: inline-grid;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  place-items: center;
  margin-left: 4px;
  border-radius: 6px;
  color: #7c8790;
  cursor: pointer;
  transition: transform 140ms ease, background-color 140ms ease, color 140ms ease;
}
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-thread-toggle:hover,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-thread-toggle:focus-visible {
  background: #e4e7ea;
  color: #3f4851;
  outline: none;
}
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-thread-toggle.is-collapsed {
  transform: rotate(-90deg);
}

.eva-msg .eva-space-card .wk-conv-compact-item--thread {
  margin-top: 1px;
  margin-bottom: 1px;
}

.eva-msg .wk-conv-compact-icon--reddot::after {
  display: none !important;
}

/* Flat project tree: retain Eva's compact chrome while removing card stacking. */
body.eva-message-hierarchy-ready .eva-msg .ch-list__scroll {
  padding: 4px 10px 12px;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card {
  margin: 2px 0 6px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card > .arco-card-header,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card > .semi-card-header {
  min-height: 30px;
  /* Project-space headers are level-one peers of My AI's role groups.
     Do not give the card wrapper an extra inset: it would make this level
     start one step later than “本地助理 / 云端分身”. */
  padding: 0;
  border: 0;
  background: transparent !important;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .arco-card-header-title,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .semi-card-header-wrapper-title {
  min-width: 0;
  padding: 0;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .arco-card-header-extra,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .semi-card-header-wrapper-extra {
  margin-left: 6px;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header {
  min-height: 28px;
  /* Keep the toggle inside its native card title box. A negative inset here
     can be clipped by the scroll container at wide rail widths. */
  width: 100%;
  margin-inline-start: 0;
  gap: var(--gds-space-1);
  padding: 0;
  border-radius: 6px;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow {
  /* Keep the same 12px chevron and 4px icon/text gap as the My AI group. */
  width: var(--gds-icon-size-chevron);
  margin-right: 0;
  color: var(--semi-color-text-2, var(--gds-color-text-secondary));
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow svg {
  width: var(--gds-icon-size-chevron);
  height: var(--gds-icon-size-chevron);
}

/* The legacy IM header used a filled triangle. The child icon now uses the
   exact My AI class and state transform; neutralize legacy wrapper rotation. */
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow {
  transform: none;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__arrow--collapsed {
  transform: none;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-category-header__name {
  color: var(--semi-color-text-2, var(--gds-color-text-secondary));
  font-size: var(--gds-type-label-medium-font-size);
  font-weight: var(--gds-font-weight-medium);
  line-height: var(--gds-type-label-medium-line-height);
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .eva-space-task-button {
  width: 26px;
  min-width: 26px;
  height: 26px;
  border-radius: 6px;
  background: transparent;
  color: #8a929a;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .eva-space-task-button:hover {
  background: #e9ecef;
  color: #46515b;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card > .arco-card-body,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card > .semi-card-body {
  padding: 0 0 2px !important;
  background: transparent;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) {
  min-height: 34px;
  margin: 0;
  padding: 5px 8px;
  border-radius: 7px;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread):hover {
  background: #eceff1;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--selected,
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--selected:hover {
  background: #e4e7ea;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) .wk-conv-compact-entity-avatar {
  width: 24px !important;
  height: 24px !important;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread {
  position: relative;
  min-height: 26px;
  margin: 0;
  padding: 2px 8px 2px calc(var(--eva-space-thread-indent, 12px) + var(--gds-space-5-5));
  border-radius: 6px;
  color: #68717a;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread::before {
  position: absolute;
  top: -1px;
  left: var(--eva-space-thread-indent, 12px);
  width: 22px;
  height: calc(50% + 1px);
  border-bottom: 1px solid #c6cbd0;
  border-left: 1px solid #c6cbd0;
  border-bottom-left-radius: 7px;
  content: '';
  pointer-events: none;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread:has(+ .wk-conv-compact-item--thread)::after {
  position: absolute;
  top: 50%;
  bottom: -1px;
  left: var(--eva-space-thread-indent, 12px);
  border-left: 1px solid #c6cbd0;
  content: '';
  pointer-events: none;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread > * {
  position: relative;
  z-index: 1;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread:hover {
  background: #eceff1;
  color: #3f4851;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread .wk-conv-compact-icon {
  width: 16px;
  color: #9aa1a8;
}

body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item--thread .wk-conv-compact-name {
  font-size: var(--gds-type-label-font-size);
  font-weight: var(--gds-font-weight-regular);
  line-height: var(--gds-type-label-line-height);
}

/* 项目分组是一级，组内群聊整体右移一级；子区随所属群聊一起移动，
   继续保留自身的连接线与二级缩进。12px 是两种第二栏共用的层级间距，
   让每一级的起点明确递进。 */
body.eva-message-hierarchy-ready
  .eva-channel-surface:not([data-eva-message-mode="my-ai"])
  .eva-space-card {
  --eva-space-group-indent: 12px;
  --eva-space-thread-indent: 12px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface:not([data-eva-message-mode="my-ai"])
  .eva-space-card
  .wk-conv-compact-item:not(.wk-conv-compact-item--thread) {
  /* Header chevron occupies 12px; group avatars occupy 24px plus an 8px gap.
     This inset aligns the visible labels to the shared 12px step. */
  width: 100%;
  margin-inline-start: 0;
  padding-inline-start: calc(var(--eva-space-group-indent) - var(--gds-space-0-5));
}

body.eva-message-hierarchy-ready
  .eva-channel-surface:not([data-eva-message-mode="my-ai"])
  .eva-space-card
  .wk-conv-compact-item--thread {
  width: 100%;
  margin-inline-start: 0;
}

/* The team-message rail and My AI rail use the same GDS list hierarchy:
   group / primary row = labelMedium, nested row = label, metadata = caption. */
body.eva-message-hierarchy-ready .eva-msg .eva-space-card .wk-conv-compact-item:not(.wk-conv-compact-item--thread) .wk-conv-compact-name {
  font-size: var(--gds-type-label-medium-font-size);
  line-height: var(--gds-type-label-medium-line-height);
  font-weight: var(--gds-font-weight-medium);
}

/* Team / My AI: one AI identity owns multiple OpenClaw session previews. */
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .ch-list__top {
  display: none;
}

body.eva-message-hierarchy-ready .eva-channel-surface[data-eva-message-mode="my-ai"] .wk-sidebar-tabbar {
  display: none !important;
}

/* 旧版身份级顶部快捷操作保持隐藏；模块级“新建”菜单由我的 AI 中栏
   标题区承载。具体 AI 的新会话仍属于该身份，并按 Hover／键盘焦点显示。 */
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-new-session {
  display: none;
  width: 28px;
  min-width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 8px;
  line-height: 0;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-new-session svg,
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-toggle svg {
  display: block;
  width: 16px;
  height: 16px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card:hover .eva-my-ai-identity-new-session,
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card:focus-within .eva-my-ai-identity-new-session,
body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-active .eva-my-ai-identity-new-session {
  display: inline-grid;
  place-items: center;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-active .eva-my-ai-identity-new-session {
  background: var(--semi-color-primary, var(--eva-action-primary, #1563eb));
  color: var(--semi-color-white, #fff);
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .ch-list__scroll {
  padding: 9px 12px 18px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card {
  margin: 4px 0 14px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card + .eva-space-card {
  padding-top: 10px;
  border-top: 1px solid var(--semi-color-border, #e8e9eb);
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card > .semi-card-header {
  min-height: 42px;
  padding: 4px 6px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-category-header {
  gap: 7px;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-category-header__arrow {
  display: none;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card .arco-card-header-title {
  min-width: 0;
  flex: 1 1 auto;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card .arco-card-header-extra {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 28px;
  line-height: 0;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-toggle {
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--semi-color-text-2, #8a8f99);
  cursor: pointer;
  line-height: 0;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-my-ai-identity-toggle:hover {
  background: var(--semi-color-fill-1, #f2f3f5);
  color: var(--semi-color-text-0, #1c1f23);
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-category-header__identity-avatar {
  display: block;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border-radius: 50%;
  object-fit: cover;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card .wk-category-header__name {
  color: var(--semi-color-text-0, #1c1f23);
  font-size: 14px;
  font-weight: 600;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .eva-space-card .wk-conv-compact-item--session {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "name time"
    "preview time";
  column-gap: 12px;
  row-gap: 1px;
  min-height: 48px;
  margin: 1px 0;
  padding: 6px 9px 6px 42px;
  align-items: center;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-conv-compact-item--session .wk-conv-compact-name {
  grid-area: name;
  min-width: 0;
  overflow: hidden;
  color: var(--semi-color-text-0, #1c1f23);
  font-size: 13px;
  font-weight: 600;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-conv-compact-session-preview {
  grid-area: preview;
  min-width: 0;
  overflow: hidden;
  color: var(--semi-color-text-2, #8a8f99);
  font-size: 12px;
  line-height: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready
  .eva-channel-surface[data-eva-message-mode="my-ai"]
  .wk-conv-compact-session-time {
  grid-area: time;
  align-self: start;
  padding-top: 2px;
  color: var(--semi-color-text-2, #8a8f99);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  line-height: 18px;
  white-space: nowrap;
}



/* The global drive is a first-level EVA surface. */
body.eva-message-hierarchy-ready .eva-drive {
  top: var(--topbar-height, 37px);
  grid-template-columns: minmax(0, 1fr);
  overflow: hidden;
}

body.eva-message-hierarchy-ready .eva-drive__side {
  display: none;
}

body.eva-message-hierarchy-ready .eva-drive__main {
  grid-column: 1;
}

body.eva-message-hierarchy-ready .eva-drive__scroll {
  padding-top: 24px;
}

body.eva-message-hierarchy-ready .eva-drive__eyebrow {
  display: none;
}

body.eva-message-hierarchy-ready .eva-drive__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

body.eva-message-hierarchy-ready .eva-drive__action {
  width: auto;
  min-height: 36px;
  padding: 0 11px;
  border-radius: var(--gds-radius-control);
  display: inline-flex;
  grid-template-columns: none;
  gap: 7px;
  box-shadow: none;
}

body.eva-message-hierarchy-ready .eva-drive__action:hover {
  box-shadow: none;
  background: var(--gds-color-surface-subtle);
}

body.eva-message-hierarchy-ready .eva-drive__table--with-source {
  min-width: 840px;
}

body.eva-message-hierarchy-ready .eva-drive__table--with-source .eva-drive__table-head,
body.eva-message-hierarchy-ready .eva-drive__table--with-source .eva-drive__row {
  grid-template-columns: minmax(230px, 1.55fr) minmax(165px, 1fr) minmax(90px, .62fr) minmax(90px, .68fr) minmax(105px, .72fr) 28px;
}

body.eva-message-hierarchy-ready .eva-drive__source-cell {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

body.eva-message-hierarchy-ready .eva-drive__source-cell > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-drive__source-icon {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.eva-message-hierarchy-ready .eva-drive__action-icon {
  width: 18px;
  height: 18px;
  border-radius: 0;
  background: transparent;
}

body.eva-message-hierarchy-ready .eva-drive__action-copy {
  display: block;
}

body.eva-message-hierarchy-ready .eva-drive__action-copy strong {
  font-size: 13px;
  font-weight: 500;
}

body.eva-message-hierarchy-ready .eva-drive__action-copy > span,
body.eva-message-hierarchy-ready .eva-drive__action > .eva-drive-icon {
  display: none;
}

body.eva-message-hierarchy-ready .eva-drive__section-head .eva-drive__side-search {
  width: min(300px, 42%);
}

body.eva-message-hierarchy-ready .eva-native-nav-suppressed,
body.eva-message-hierarchy-ready .eva-native-nav-suppressed:hover {
  background: transparent !important;
}

body.eva-message-hierarchy-ready .eva-contacts-underlay-suppressed,
body.eva-message-hierarchy-ready .eva-contacts-underlay-suppressed:hover {
  background: transparent !important;
}

body.eva-message-hierarchy-ready .eva-my-avatar-underlay-suppressed,
body.eva-message-hierarchy-ready .eva-my-avatar-underlay-suppressed:hover {
  background: transparent !important;
}

body.eva-message-hierarchy-ready .eva-space-workbench {
  --eva-space-accent: #6569e8;
  --eva-space-accent-soft: #f1f1fb;
  --eva-space-accent-line: #dcdcf5;
  box-sizing: border-box;
  min-width: 0;
  overflow: hidden;
  border: 1px solid #e1e4e8;
  border-radius: 15px;
  background: #fff;
}

body.eva-message-hierarchy-ready .eva-space-workbench--delivery {
  --eva-space-accent: #14866d;
  --eva-space-accent-soft: #edf7f3;
  --eva-space-accent-line: #d5ebe4;
}

body.eva-message-hierarchy-ready .eva-space-workbench__header {
  min-height: 74px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--eva-space-accent-line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--eva-space-accent-soft);
}

body.eva-message-hierarchy-ready .eva-space-workbench__identity,
body.eva-message-hierarchy-ready .eva-space-workbench__identity > span:last-child {
  min-width: 0;
  display: flex;
}

body.eva-message-hierarchy-ready .eva-space-workbench__identity {
  align-items: center;
  gap: 12px;
}

body.eva-message-hierarchy-ready .eva-space-workbench__identity > span:last-child {
  flex-direction: column;
  gap: 2px;
}

body.eva-message-hierarchy-ready .eva-space-workbench__mark {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--eva-space-accent);
  font-size: 15px;
  font-weight: 720;
}

body.eva-message-hierarchy-ready .eva-space-workbench__identity strong {
  overflow: hidden;
  color: #24272c;
  font-size: 16px;
  font-weight: 680;
  line-height: 22px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-workbench__identity em {
  overflow: hidden;
  color: #717680;
  font-size: 12px;
  font-style: normal;
  line-height: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-workbench__enter {
  min-height: 32px;
  padding: 0 10px 0 12px;
  border: 0;
  border-radius: 8px;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 4px;
  color: var(--eva-space-accent);
  background: rgba(255, 255, 255, 0.72);
  font: inherit;
  font-size: 12px;
  font-weight: 620;
  cursor: pointer;
}

body.eva-message-hierarchy-ready .eva-space-workbench__enter:hover {
  background: #fff;
}

body.eva-message-hierarchy-ready .eva-space-workbench__enter svg {
  width: 14px;
  height: 14px;
}

body.eva-message-hierarchy-ready .eva-space-workbench__body {
  padding: 18px;
}

body.eva-message-hierarchy-ready .eva-space-workbench__projects h3 {
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #656a72;
  font-size: 12px;
  font-weight: 620;
}

body.eva-message-hierarchy-ready .eva-space-workbench__projects h3 svg,
body.eva-message-hierarchy-ready .eva-space-workbench button svg,
body.eva-message-hierarchy-ready .eva-space-workbench__connector svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.eva-message-hierarchy-ready .eva-space-workbench__projects h3 svg {
  width: 15px;
  height: 15px;
}

body.eva-message-hierarchy-ready .eva-space-projects {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

body.eva-message-hierarchy-ready .eva-space-project {
  box-sizing: border-box;
  min-width: 0;
  min-height: 66px;
  padding: 10px 12px;
  border: 1px solid #e6e8eb;
  border-radius: 10px;
  display: grid;
  grid-template-columns: minmax(130px, 1fr) minmax(72px, 120px) 36px;
  align-items: center;
  gap: 12px;
  color: inherit;
  background: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

body.eva-message-hierarchy-ready .eva-space-project:hover {
  border-color: var(--eva-space-accent-line);
  background: #fafafa;
}

body.eva-message-hierarchy-ready .eva-space-project > span:first-child {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.eva-message-hierarchy-ready .eva-space-project strong {
  overflow: hidden;
  color: #30343a;
  font-size: 13px;
  font-weight: 620;
  line-height: 19px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-project em {
  color: #8a8f98;
  font-size: 11px;
  font-style: normal;
  line-height: 17px;
}

body.eva-message-hierarchy-ready .eva-space-project--risk em,
body.eva-message-hierarchy-ready .eva-space-workflow__warning,
body.eva-message-hierarchy-ready .eva-space-foundation__error {
  color: #b76a12 !important;
}

body.eva-message-hierarchy-ready .eva-space-project__progress {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #edf0f2;
}

body.eva-message-hierarchy-ready .eva-space-project__progress i {
  width: var(--eva-progress);
  height: 100%;
  border-radius: inherit;
  display: block;
  background: var(--eva-space-accent);
}

body.eva-message-hierarchy-ready .eva-space-project > b {
  color: #626771;
  font-size: 12px;
  font-weight: 620;
  text-align: right;
}

body.eva-message-hierarchy-ready .eva-space-workflow {
  margin-top: 16px;
  padding: 14px;
  border-radius: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 24px minmax(0, 1.55fr) 24px minmax(0, 1fr);
  align-items: stretch;
  gap: 8px;
  background: #f7f8fa;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node {
  box-sizing: border-box;
  min-width: 0;
  min-height: 74px;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  background: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node:hover {
  border-color: var(--eva-space-accent-line);
}

body.eva-message-hierarchy-ready .eva-space-workflow__executors {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.eva-message-hierarchy-ready .eva-space-workflow__icon {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: var(--eva-space-accent);
  background: var(--eva-space-accent-soft);
}

body.eva-message-hierarchy-ready .eva-space-workflow__icon svg {
  width: 17px;
  height: 17px;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node > span:last-child {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node em,
body.eva-message-hierarchy-ready .eva-space-workflow__node small {
  overflow: hidden;
  color: #8a8f98;
  font-size: 11px;
  font-style: normal;
  line-height: 16px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node strong {
  overflow: hidden;
  color: #32363c;
  font-size: 13px;
  font-weight: 640;
  line-height: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node small b {
  color: var(--eva-space-accent);
  font-weight: 700;
}

body.eva-message-hierarchy-ready .eva-space-workflow__connector {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #b8bcc3;
}

body.eva-message-hierarchy-ready .eva-space-workflow__connector svg {
  width: 17px;
  height: 17px;
}

body.eva-message-hierarchy-ready .eva-space-workflow__node--result .eva-space-workflow__icon {
  color: #3e7b62;
  background: #eaf5ef;
}

body.eva-message-hierarchy-ready .eva-space-foundation {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #eceef0;
  display: flex;
  align-items: center;
  gap: 8px;
}

body.eva-message-hierarchy-ready .eva-space-foundation__label {
  margin-right: 4px;
  color: #8a8f98;
  font-size: 11px;
  white-space: nowrap;
}

body.eva-message-hierarchy-ready .eva-space-foundation > button {
  min-height: 42px;
  padding: 6px 10px;
  border: 0;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #5f646c;
  background: #f7f8fa;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

body.eva-message-hierarchy-ready .eva-space-foundation > button:hover {
  background: #eef0f3;
}

body.eva-message-hierarchy-ready .eva-space-foundation > button > svg {
  width: 16px;
  height: 16px;
  color: var(--eva-space-accent);
}

body.eva-message-hierarchy-ready .eva-space-foundation > button > span {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

body.eva-message-hierarchy-ready .eva-space-foundation strong {
  color: #454a51;
  font-size: 12px;
  font-weight: 620;
  line-height: 17px;
}

body.eva-message-hierarchy-ready .eva-space-foundation em {
  color: #92969d;
  font-size: 10px;
  font-style: normal;
  line-height: 15px;
}

body.eva-message-hierarchy-ready .eva-space-workbench button:focus-visible{
  outline: 2px solid var(--semi-color-focus-border, #4c6ef5);
  outline-offset: 2px;
}

@media (max-width: 1100px) {

  body.eva-message-hierarchy-ready .eva-space-workflow {
    grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1.4fr) 18px minmax(0, 1fr);
    gap: 5px;
  }

  body.eva-message-hierarchy-ready .eva-space-workflow__executors {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {

  body.eva-message-hierarchy-ready .eva-space-projects {
    grid-template-columns: 1fr;
  }

  body.eva-message-hierarchy-ready .eva-space-workflow {
    grid-template-columns: 1fr;
  }

  body.eva-message-hierarchy-ready .eva-space-workflow__connector {
    display: none;
  }

  body.eva-message-hierarchy-ready .eva-space-foundation {
    align-items: stretch;
    flex-direction: column;
  }

  body.eva-message-hierarchy-ready .eva-space-foundation__label {
    margin: 0 0 2px;
  }
}

/* The Space page reuses the same identity color without inventing a Space avatar. */
body.eva-message-hierarchy-ready .collab-frame.eva-space-card-foundation > .collab-tabs {
  border-bottom-color: var(--eva-space-card-border);
  background: linear-gradient(
    90deg,
    var(--eva-space-card-surface) 0 clamp(160px, 18vw, 220px),
    #fff clamp(460px, 48vw, 620px)
  );
}

body.eva-message-hierarchy-ready .collab-frame.eva-space-card-foundation .collab-sp-chip {
  color: var(--eva-space-card-accent);
}

body.eva-message-hierarchy-ready .collab-frame.eva-space-card-foundation .collab-sp-chip > .semi-avatar {
  display: none;
}

body.eva-message-hierarchy-ready .collab-frame.eva-space-card-foundation .collab-sp-chip:hover {
  background: rgb(255 255 255 / 62%);
}

body.eva-message-hierarchy-ready .eva-my-avatar-chat {
  position: fixed;
  z-index: 71;
  top: var(--topbar-height, 37px);
  right: 0;
  bottom: 0;
  left: var(--eva-drive-left, 260px);
  min-width: 0;
  overflow: hidden;
  color: var(--semi-color-text-0, #1c1f23);
  background: var(--semi-color-bg-0, #fff);
  font-family: inherit;
}

body.eva-message-hierarchy-ready .eva-my-avatar-chat[hidden] {
  display: none;
}

body.eva-message-hierarchy-ready .eva-my-avatar-chat > .ch-main__col {
  width: 100%;
  height: 100%;
}

body.eva-message-hierarchy-ready .eva-my-avatar-chat__portrait {
  display: block;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.eva-tb-portrait {
  display: block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.eva-user-row img.ava {
  object-fit: cover;
}

body.eva-message-hierarchy-ready .eva-my-avatar-chat .ch-head .ops .op {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

body.eva-message-hierarchy-ready .eva-msg .eva-dm-scope .wk-conv-compact-item--thread,
body.eva-message-hierarchy-ready .eva-msg.eva-private-chat-selected .ch-head .op[title="子区"],
body.eva-message-hierarchy-ready .eva-msg.eva-private-chat-selected .wk-thread-panel {
  display: none !important;
}

body.eva-message-hierarchy-ready .eva-contacts__header {
  box-sizing: border-box;
  height: 64px;
  padding: 0 24px;
  border-bottom: 1px solid var(--semi-color-border, #eceef0);
  display: flex;
  align-items: center;
}

body.eva-message-hierarchy-ready .eva-contacts__header strong {
  font-size: 16px;
  font-weight: 600;
}

body.eva-message-hierarchy-ready .eva-contacts__empty {
  position: absolute;
  inset: 64px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

body.eva-message-hierarchy-ready .eva-contacts__empty svg {
  width: 56px;
  height: 56px;
  fill: none;
  stroke: var(--semi-color-text-3, #c8cbd0);
  stroke-width: 1.25;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.eva-message-hierarchy-ready .eva-space-tree-parent {
  position: relative;
  padding-inline-end: 34px !important;
}

body.eva-message-hierarchy-ready .eva-space-tree-parent__chevron {
  position: absolute;
  top: 50%;
  right: 10px;
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--semi-color-text-2, #737780);
  transform: translateY(-50%);
  transition: transform 160ms ease;
}

body.eva-message-hierarchy-ready .eva-space-tree-parent__chevron svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.eva-message-hierarchy-ready .eva-space-tree-parent[aria-expanded="false"] .eva-space-tree-parent__chevron {
  transform: translateY(-50%) rotate(-90deg);
}

body.eva-message-hierarchy-ready .eva-space-tree-parent--child-active,
body.eva-message-hierarchy-ready .eva-space-tree-parent--child-active:hover {
  color: var(--semi-color-text-0, #1c1f23) !important;
  background: transparent !important;
}

body.eva-message-hierarchy-ready .eva-space-tree {
  position: relative;
  box-sizing: border-box;
  margin: 0 8px 2px 20px;
  padding: 2px 0 2px 13px;
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  gap: 2px;
}

body.eva-message-hierarchy-ready .eva-space-tree[hidden] {
  display: none;
}

body.eva-message-hierarchy-ready .eva-space-tree::before {
  content: '';
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: 0;
  width: 1px;
  background: var(--semi-color-border, #dfe1e5);
}

body.eva-message-hierarchy-ready .eva-space-tree__item {
  box-sizing: border-box;
  width: 100%;
  min-height: 34px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  color: var(--semi-color-text-0, #1c1f23);
  background: transparent;
  font: inherit;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}

body.eva-message-hierarchy-ready .eva-space-tree__item:hover,
body.eva-message-hierarchy-ready .eva-space-tree__item[aria-current="page"] {
  background: var(--semi-color-fill-1, #e2e3e5);
}

body.eva-message-hierarchy-ready .eva-space-tree__item[aria-current="page"] {
  font-weight: 550;
}

/* Message file actions follow the Octo state contract. The file card and
   context menu share save/view icons; the fixed nav uses the view icon. */
body.eva-message-hierarchy-ready .eva-msg .wk-message-file-actions {
  flex-shrink: 0;
}

body.eva-message-hierarchy-ready .eva-msg .wk-message-file-action svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  stroke-width: 2;
}

body.eva-message-hierarchy-ready .eva-msg .eva-file-drive-action:focus-visible {
  outline: 2px solid var(--semi-color-focus-border, #4c6ef5);
  outline-offset: 1px;
}

body.eva-message-hierarchy-ready .eva-msg .wk-message-file.eva-message-source-highlight {
  outline: 2px solid var(--semi-color-primary, #1456f0);
  outline-offset: 3px;
  animation: eva-message-source-pulse 1.1s ease-in-out 2;
}

@keyframes eva-message-source-pulse {
  50% { box-shadow: 0 0 0 6px rgb(20 86 240 / 12%); }
}

@media (prefers-reduced-motion: reduce) {
  body.eva-message-hierarchy-ready .eva-msg .wk-message-file.eva-message-source-highlight { animation: none; }
}

body.eva-message-hierarchy-ready .eva-space-tree__item:focus-visible {
  outline: 2px solid var(--semi-color-focus-border, #4c6ef5);
  outline-offset: 1px;
}

@media (max-width: 920px) {
  body.eva-message-hierarchy-ready .eva-drive__scroll {
    padding-inline: 18px;
  }

}

/* Custom conversation categories reuse the message rail and shared modal. */
.eva-category-conversations { max-height: 300px; overflow-y: auto; margin-top: 8px; }
.eva-category-conversation { display: flex; align-items: center; gap: 8px; min-height: 36px; cursor: pointer; }
.eva-category-conversation img { border-radius: 50%; flex-shrink: 0; }
.eva-category-conversation span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Chat owns the full project content surface, matching the other rails. */
.collab-body:has(> .ch-layout) { padding-inline: 0; }
