/* 鱼摆摆 · 桌面端设计令牌与微交互层
 * 最后加载，只覆盖色彩、阴影、圆角、过渡与焦点反馈；不改变布局结构、DOM 选择器与数据属性。
 * 品牌：深水墨 + 湖水青渐变，暖珊瑚作稀缺强调色。 */
:root {
  --yb-ink: #0d1d22;
  --yb-ink-2: #1c3036;
  --yb-ink-3: #3a5057;
  --yb-muted: #5a6d72;
  --yb-faint: #8a9a9e;
  --yb-line: #e3ecec;
  --yb-line-strong: #cfdcdc;
  --yb-canvas: #f6f9f9;
  --yb-paper: #ffffff;
  --yb-water: #0b7a83;
  --yb-water-2: #2bb3b1;
  --yb-water-soft: #e8f6f5;
  --yb-water-mist: #f2faf9;
  --yb-coral: #ff7a59;
  --yb-coral-soft: #fff1ec;
  --yb-danger: #c2412d;
  --yb-grad: linear-gradient(135deg, #0b7a83 0%, #2bb3b1 100%);
  --yb-grad-ink: linear-gradient(180deg, #1c3036 0%, #0d1d22 100%);
  --yb-shadow-1: 0 1px 2px rgb(13 29 34 / 5%), 0 2px 8px rgb(13 29 34 / 4%);
  --yb-shadow-2: 0 2px 6px rgb(13 29 34 / 5%), 0 12px 32px rgb(13 29 34 / 8%);
  --yb-shadow-3: 0 8px 24px rgb(13 29 34 / 8%), 0 32px 80px rgb(13 29 34 / 16%);
  --yb-glow: 0 0 0 4px rgb(43 179 177 / 18%);
  --yb-ease: cubic-bezier(.22, 1, .36, 1);
  --yb-fast: 140ms;
  --yb-mid: 240ms;
  --yb-slow: 420ms;

  /* 与既有令牌对齐，使旧组件自动继承新色彩 */
  --ink: var(--yb-ink);
  --muted: var(--yb-muted);
  --line: var(--yb-line);
  --green: var(--yb-water);
  --green-soft: var(--yb-water-soft);
  --xy-ink: var(--yb-ink);
  --xy-deep: var(--yb-ink);
  --xy-deep-2: var(--yb-ink-2);
  --xy-green: var(--yb-water);
  --xy-green-dark: #075f66;
  --xy-mint: var(--yb-water-mist);
  --xy-line: var(--yb-line);
  --xy-muted: var(--yb-muted);
  --xy-shadow-1: var(--yb-shadow-1);
  --xy-shadow-2: var(--yb-shadow-2);
  --xy-shadow-3: var(--yb-shadow-3);
  --xy-ease: var(--yb-ease);
  accent-color: var(--yb-water);
  -webkit-font-smoothing: auto;
  text-rendering: auto;
}

::selection { background: rgb(43 179 177 / 24%); color: var(--yb-ink); }

/* ---------- 滚动条：细、安静、悬停可见 ---------- */
* { scrollbar-width: thin; scrollbar-color: rgb(13 29 34 / 16%) transparent; }
*::-webkit-scrollbar { width: 10px; height: 10px; }
*::-webkit-scrollbar-thumb { background: rgb(13 29 34 / 14%); border-radius: 999px; border: 3px solid transparent; background-clip: padding-box; }
*::-webkit-scrollbar-thumb:hover { background-color: rgb(13 29 34 / 28%); }
*::-webkit-scrollbar-track { background: transparent; }

/* ---------- 焦点：可访问的柔光焦点环 ---------- */
:where(button, a, summary, [tabindex]):focus-visible,
:where(input, select, textarea):focus-visible {
  outline: 2px solid var(--yb-water-2);
  outline-offset: 2px;
}

/* ---------- 按钮体系 ---------- */
.button {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition: background-color var(--yb-fast) var(--yb-ease), border-color var(--yb-fast) var(--yb-ease),
    color var(--yb-fast) var(--yb-ease), box-shadow var(--yb-mid) var(--yb-ease), transform var(--yb-fast) var(--yb-ease);
  -webkit-tap-highlight-color: transparent;
}
.button:active:not(:disabled) { transform: translateY(1px) scale(.985); }
.button:disabled { cursor: not-allowed; opacity: .52; }

.button.primary {
  background: var(--yb-grad-ink);
  border: 1px solid var(--yb-ink);
  color: #fff;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 12%), 0 1px 2px rgb(13 29 34 / 18%), 0 4px 14px rgb(13 29 34 / 12%);
}
.button.primary:hover:not(:disabled) {
  background: linear-gradient(180deg, #24414a 0%, #11262c 100%);
  border-color: #11262c;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 14%), 0 2px 4px rgb(13 29 34 / 18%), 0 10px 26px rgb(11 122 131 / 22%);
}
.button.secondary {
  background: var(--yb-paper);
  border: 1px solid var(--yb-line-strong);
  color: var(--yb-ink-2);
  box-shadow: var(--yb-shadow-1);
}
.button.secondary:hover:not(:disabled) { border-color: rgb(11 122 131 / 45%); color: var(--yb-water); background: var(--yb-water-mist); }
.button.quiet:hover:not(:disabled) { background: rgb(11 122 131 / 7%); color: var(--yb-water); }

/* ---------- 表单控件 ---------- */
input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]), select, textarea {
  transition: border-color var(--yb-fast) var(--yb-ease), box-shadow var(--yb-mid) var(--yb-ease), background-color var(--yb-fast);
}
input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]):hover:not(:disabled),
select:hover:not(:disabled), textarea:hover:not(:disabled) { border-color: var(--yb-line-strong); }
input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=range]):focus,
select:focus, textarea:focus {
  border-color: var(--field-focus-border, var(--yb-water-2)) !important;
  box-shadow: var(--yb-glow);
  outline: none;
}

/* ---------- 侧栏与导航 ---------- */
.sidebar .nav-item {
  position: relative;
  overflow: hidden;
  transition: background-color var(--yb-fast) var(--yb-ease), color var(--yb-fast) var(--yb-ease), padding var(--yb-mid) var(--yb-ease);
}
.sidebar .nav-item:hover { background: var(--yb-water-mist); color: var(--yb-ink); }
.sidebar .nav-item.active {
  background: linear-gradient(90deg, var(--yb-water-soft) 0%, rgb(232 246 245 / 40%) 100%);
  color: var(--yb-ink);
}
.sidebar .nav-item.active::after {
  content: '';
  position: absolute;
  left: 0; top: 22%; bottom: 22%;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--yb-grad);
  animation: yb-indicator var(--yb-mid) var(--yb-ease);
}
.sidebar .nav-item.active svg { color: var(--yb-water); }
@keyframes yb-indicator { from { transform: scaleY(0); opacity: 0; } to { transform: scaleY(1); opacity: 1; } }

.sidebar, .ref-sidebar { transition: width var(--yb-slow) var(--yb-ease), box-shadow var(--yb-mid) var(--yb-ease); }
.ref-rail-button { position: relative; overflow: hidden; transition: background-color var(--yb-fast) var(--yb-ease), color var(--yb-fast) var(--yb-ease), transform var(--yb-fast) var(--yb-ease); }
.ref-rail-button:active { transform: scale(.94); }
.ref-history-item, .social-room, .recent-item {
  transition: background-color var(--yb-fast) var(--yb-ease), transform var(--yb-fast) var(--yb-ease), box-shadow var(--yb-mid) var(--yb-ease);
}
.ref-history-item:hover, .social-room:hover, .recent-item:hover { background: var(--yb-water-mist); }

/* ---------- 卡片与面板 ---------- */
:where(.plan, .dlb-card, .creative-panel, .production-panel, .fishing-analysis, .simple-task, .business-home, .welcome-source, .provider-row, .project-list-row) {
  transition: box-shadow var(--yb-mid) var(--yb-ease), border-color var(--yb-mid) var(--yb-ease), transform var(--yb-mid) var(--yb-ease);
}
:where(.plan, .dlb-card, .welcome-source, .project-list-row):hover {
  border-color: rgb(11 122 131 / 28%);
  box-shadow: var(--yb-shadow-2);
}
.plans-page .plan.chosen {
  border-color: color-mix(in srgb, var(--yb-water) 45%, var(--yb-line));
  box-shadow: var(--yb-shadow-1);
}
.plans-page .cloud-configured-plans .plan-allowances dt,
.creative-balance .creative-plan-points dt {
  flex-shrink: 0;
}
.plans-page .cloud-configured-plans .plan-allowances dd,
.creative-balance .creative-plan-points dd {
  text-align: right;
  white-space: normal;
}

.tag { letter-spacing: .01em; }
.tag.accent { background: var(--yb-water-soft); color: var(--yb-water); border-color: transparent; }

.notice {
  background: linear-gradient(135deg, var(--yb-water-mist) 0%, #fbfdfd 100%);
  border: 1px solid rgb(11 122 131 / 14%);
  color: var(--yb-ink-3);
}
.notice svg { color: var(--yb-water); }

/* ---------- 弹窗：柔和入场 ---------- */
dialog[open], .desktop-search-dialog[open], .model-picker-dialog[open] {
  animation: yb-dialog-in var(--yb-slow) var(--yb-ease);
  box-shadow: var(--yb-shadow-3), 0 0 0 1px rgb(13 29 34 / 4%);
}
dialog[open]::backdrop {
  background: rgb(13 29 34 / 28%);
  backdrop-filter: none;
  animation: yb-fade-in var(--yb-mid) var(--yb-ease);
}
[role=dialog][aria-modal=true] { animation: yb-dialog-in var(--yb-slow) var(--yb-ease); }
@keyframes yb-dialog-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
[role=dialog][data-modal-continuation=true] { animation: none; }
@keyframes yb-fade-in { from { opacity: 0; } to { opacity: 1; } }

/* 弹出菜单与浮层 */
:where(.model-picker-popover, .ref-account-popover, .ref-workspace-popover, .ref-attachment-menu, .ref-phone-more-popover) {
  animation: yb-pop-in var(--yb-mid) var(--yb-ease);
  transform-origin: top left;
}
@keyframes yb-pop-in { from { opacity: 0; transform: translateY(-4px) scale(.97); } to { opacity: 1; transform: none; } }

/* ---------- 通知 ---------- */
.toast { animation: yb-toast-in 160ms var(--yb-ease); }
@keyframes yb-toast-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }


/* ---------- 加载骨架屏 ---------- */
.initial-state {
  position: relative;
}
.yb-loading-text { color: var(--yb-muted); }

.initial-state {
  display: grid;
  place-items: center;
  min-height: 100dvh;
  color: var(--yb-muted);
  background:
    radial-gradient(60% 50% at 50% 40%, rgb(43 179 177 / 10%) 0%, transparent 70%),
    var(--yb-canvas);
}
.initial-state[role=status]::before {
  content: '';
  width: 44px; height: 44px;
  margin-bottom: 14px;
  border-radius: 50%;
  border: 3px solid rgb(11 122 131 / 14%);
  border-top-color: var(--yb-water-2);
  animation: yb-spin 900ms linear infinite;
  justify-self: center;
}
@keyframes yb-spin { to { transform: rotate(360deg); } }

/* ---------- 空状态 ---------- */
.empty-state, .sidebar-empty, .social-empty-chat, .ref-task-empty {
  position: relative;
}
.empty-state {
  background:
    radial-gradient(50% 60% at 50% 0%, rgb(43 179 177 / 9%) 0%, transparent 70%),
    var(--yb-paper);
  border: 1px dashed var(--yb-line-strong);
  border-radius: 22px;
}
.empty-state > svg {
  color: var(--yb-water);
  padding: 16px;
  width: 72px; height: 72px;
  border-radius: 22px;
  background: var(--yb-water-soft);
  box-shadow: inset 0 0 0 1px rgb(11 122 131 / 10%);
  animation: yb-float 4.2s ease-in-out infinite;
}
@keyframes yb-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }

/* ---------- 登录页品牌化 ---------- */
/* 登录与首次注册页高定双栏 / 半屏居中卡片系统 */
.login-page {
  max-width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 432px);
  justify-content: center;
  align-items: center;
  gap: clamp(32px, 5vw, 76px);
  padding: clamp(28px, 5vh, 64px) clamp(24px, 6vw, 88px);
}
.login-intro {
  max-width: 540px;
  justify-self: center;
  width: 100%;
  min-width: 0;
}
.login-intro h1 {
  font-size: clamp(30px, 3.2vw, 44px);
  font-weight: 700;
  line-height: 1.24;
  letter-spacing: -.03em;
}
.login-intro > p {
  font-size: 14.5px;
  line-height: 1.75;
  color: #525f6c;
}
.login-panel {
  width: 100%;
  min-width: 0;
  padding: 34px 34px 28px;
  border-radius: 24px;
  background: rgb(255 255 255 / 96%);
  backdrop-filter: blur(16px) saturate(135%);
  border: 1px solid #e2e8ee;
  box-shadow:
    0 1px 3px rgb(15 23 42 / 4%),
    0 24px 52px -14px rgb(15 23 42 / 11%);
}
.login-panel > h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: #111827;
  margin-bottom: 6px;
}
.login-panel > .muted {
  font-size: 13.5px;
  color: #5e6a75;
  margin-bottom: 22px;
  line-height: 1.6;
}
.login-panel .login-form {
  display: grid;
  gap: 14px;
}
.login-panel .field {
  margin: 0;
}
.login-panel .field-label,
.login-panel .field > label {
  font-size: 12.5px;
  font-weight: 600;
  color: #374151;
}
.login-panel .field input {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid #dbe2e8;
  background: #fbfcfd;
  font-size: 14px;
  color: #111827;
}
.login-panel .field input:focus {
  background: #fff;
  border-color: #0e7490;
  box-shadow: 0 0 0 3px rgb(14 116 144 / 12%);
}
.login-panel .login-submit {
  width: 100%;
  min-height: 46px;
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 12px;
  background: linear-gradient(180deg, #1a222b 0%, #11161c 100%);
  border: 1px solid #11161c;
  color: #fff;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: .01em;
  box-shadow: 0 4px 12px rgb(17 22 28 / 16%);
}
.login-panel .login-submit:hover:not(:disabled) {
  background: linear-gradient(180deg, #242e39 0%, #171d25 100%);
  box-shadow: 0 6px 16px rgb(17 22 28 / 22%);
}
.login-panel .demo-accounts {
  margin-top: 16px;
  font-size: 12px;
  line-height: 1.65;
  color: #6b7682;
}
.login-panel .desktop-legal-links {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed #eaedf1;
  font-size: 12px;
  line-height: 1.65;
  color: #77828d;
  overflow-wrap: anywhere;
}
.login-panel .desktop-legal-links a {
  color: #0e7490;
  text-decoration: none;
}
.login-panel .desktop-legal-links a:hover {
  text-decoration: underline;
}

/* 针对分屏窗口或 1040px 以下宽度：自动切换为优雅单栏居中卡片，杜绝右侧裁切与首屏截断 */
@media (max-width: 1040px) {
  .login-page,
  .welcome-registration {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
    justify-items: center;
    gap: 14px;
    padding: 20px 20px 36px;
  }
  .login-intro,
  .welcome-registration-intro {
    max-width: 460px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .login-page .login-brand,
  .login-intro .login-brand {
    position: static;
    inset: auto;
    margin: 0 auto 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
  }
  .login-intro > .xiaoyu-pet {
    width: 72px;
    height: 72px;
    margin-bottom: 6px;
  }
  .login-intro h1,
  .welcome-registration-intro h1 {
    font-size: 24px;
    margin: 2px 0 6px;
  }
  .login-intro > p {
    font-size: 13px;
    margin-bottom: 8px;
    line-height: 1.55;
  }
  .login-panel,
  .welcome-registration-form {
    max-width: 460px;
    padding: 24px 24px 22px;
    border-radius: 22px;
  }
}
@media (max-width: 520px) {
  .login-page,
  .welcome-registration {
    padding: 20px 14px 32px;
  }
  .login-panel,
  .welcome-registration-form {
    padding: 24px 18px 20px;
    border-radius: 20px;
  }
}

/* ==========================================================================
   湖光工作室 · 统一跨模块桌面精细视觉层（设置弹窗 / 侧边栏 / 社交模型 / 日常工作区）
   ========================================================================== */

dialog::backdrop {
  background: rgb(15 23 42 / 26%);
  backdrop-filter: blur(2px);
}

/* 2. 左边栏冷霜分层质感与列表紧凑度优化 */
.ref-rail,
.ref-sidebar {
  background: #f7f9fb;
  border-right: 1px solid #e5eaef;
}
.ref-sidebar .ref-sidebar-tab.active,
.ref-sidebar .ref-sidebar-tab[aria-selected="true"] {
  background: #fff;
  color: #111827;
  font-weight: 600;
  box-shadow: 0 1px 3px rgb(15 23 42 / 7%);
}
.ref-sidebar .social-room,
.ref-sidebar .ref-history-item {
  border-radius: 12px;
  padding: 9px 10px;
  border: 1px solid transparent;
}
.ref-sidebar .social-room:hover,
.ref-sidebar .ref-history-item:hover {
  background: #eef3f7;
}
.ref-sidebar .social-room.active,
.ref-sidebar .ref-history-item.active {
  background: #fff;
  border-color: #dfe6ed;
  box-shadow: 0 1px 3px rgb(15 23 42 / 4%);
}
.ref-sidebar .social-sidebar-action,
.ref-sidebar .ref-sidebar-action {
  min-height: 34px;
  padding: 6px 10px;
  border-radius: 9px;
  font-size: 13px;
  color: #374151;
}
.ref-sidebar .social-sidebar-action:hover,
.ref-sidebar .ref-sidebar-action:hover {
  background: #eaeff4;
  color: #111827;
}

/* 3. 群聊头部、消息流元信息、统一输入框与模型选择气泡 */
.social-chat-head {
  height: 58px;
  padding: 0 18px;
  gap: 10px;
  border-bottom: 1px solid #ebeff3;
  background: #fff;
}
.social-message-meta {
  font-size: 12px;
  color: #74808c;
  font-variant-numeric: tabular-nums;
}
.social-composer-unified {
  border: 1px solid #dce3ea;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 2px 10px rgb(15 23 42 / 4%), 0 10px 28px -8px rgb(15 23 42 / 5%);
  transition: border-color .16s ease, box-shadow .16s ease;
}
.social-composer-unified:focus-within {
  border-color: #0e7490;
  box-shadow: 0 0 0 3px rgb(14 116 144 / 9%), 0 10px 28px -8px rgb(15 23 42 / 8%);
}
.social-composer-model {
  min-height: 32px;
  padding: 4px 10px;
  border-radius: 10px;
  border: 1px solid #e2e8ee;
  background: #f5f7f9;
  color: #171e26;
  font-size: 12.5px;
  font-weight: 500;
  gap: 6px;
}
.social-composer-model:hover:not(:disabled) {
  background: #edf1f5;
  border-color: #cfd8e0;
}
.social-send {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #14191f;
  color: #fff;
}
.social-send:hover:not(:disabled) {
  background: #0e7490;
}
.social-send:disabled {
  background: #cbd5df;
  color: #fff;
  opacity: 1;
}

/* 模型弹出菜单精雕细琢：固定左侧图标宽度、左对齐文字、消除背板错位与遮挡 */
.social-model-menu {
  box-shadow:
    0 4px 14px rgb(15 23 42 / 6%),
    0 20px 44px -10px rgb(15 23 42 / 14%);
}
.social-model-menu .social-picker-caption {
  font-size: 13px;
  font-weight: 650;
  color: #111827;
  padding: 2px 4px 6px;
}
.social-model-menu .social-model-current {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  margin: 4px 2px 6px;
  border-radius: 12px;
  background: #f7f9fb;
  border: 1px solid #e7edf2;
}
.social-model-menu .social-model-current > .tactile-provider-mark,
.social-model-menu .social-model-option > .tactile-provider-mark,
.social-model-menu .social-model-current > span:first-child,
.social-model-menu .social-model-option > span:first-child {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #e4e9ee;
}
.social-model-menu .social-model-current > span:last-child,
.social-model-menu .social-model-option > span:has(> strong) {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.social-model-menu .social-model-current > span:last-child small,
.social-model-menu .social-model-option small {
  font-size: 12px;
  color: #64707a;
}
.social-model-source-tab.active,
.social-model-source-tab[aria-pressed="true"] {
  background: #fff;
  color: #0e7490;
  font-weight: 600;
  box-shadow: 0 1px 3px rgb(15 23 42 / 8%);
}
.social-model-menu input[type="search"],
.social-model-search input {
  width: 100%;
  min-height: 36px;
  padding: 6px 12px;
  border: 1px solid #e1e7ed;
  border-radius: 10px;
  background: #f8fafc;
  font-size: 13px;
  margin-bottom: 6px;
}
.social-model-menu input[type="search"]:focus,
.social-model-search input:focus {
  background: #fff;
  border-color: #0e7490;
  outline: none;
  box-shadow: 0 0 0 3px rgb(14 116 144 / 10%);
}
.social-model-option {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  border-radius: 11px;
  padding: 9px 11px;
  margin-bottom: 3px;
  border: 1px solid transparent;
  transition: background-color .14s ease, border-color .14s ease;
}
.social-model-option:hover:not(:disabled) {
  background: #f4f7fa;
}
.social-model-option.selected,
.social-model-option[aria-pressed="true"] {
  background: #edf6f8;
  border-color: #cce5eb;
}
.social-latest {
  top: -54px;
  box-shadow: 0 3px 12px rgb(15 23 42 / 8%);
  border: 1px solid #dce3ea;
}
@media (max-width: 560px) {
  .social-composer-area {
    padding: 0 14px 12px;
  }
  .social-composer-unified {
    border-radius: 18px;
  }
}

/* 4. 日常任务工作台、快捷入口条与输入框统一焦点质感 */
.daily-page .ref-task-context {
  background: transparent;
  border: 0;
  border-radius: 0;
  width: 100%;
  padding: 0 2px 10px;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.daily-page .ref-task-context > button,
.daily-page .ref-task-context > a {
  min-height: 30px;
  padding: 4px 11px;
  border-radius: 9px;
  background: #fff;
  border: 1px solid #e2e8ee;
  color: #4b5563;
  font-size: 12px;
}
.daily-page .ref-task-context > button:hover,
.daily-page .ref-task-context > a:hover {
  background: #f5f8fa;
  border-color: #cbd5e1;
  color: #111827;
}
.daily-page .daily-composer {
  border: 1px solid #dce3ea;
  border-radius: 22px;
  box-shadow: 0 2px 10px rgb(15 23 42 / 4%), 0 10px 28px -8px rgb(15 23 42 / 5%);
}
.daily-page .daily-composer:focus-within {
  border-color: #0e7490;
  box-shadow: 0 0 0 3px rgb(14 116 144 / 9%), 0 10px 28px -8px rgb(15 23 42 / 8%);
}
.daily-page .daily-send {
  border-radius: 12px;
  background: #14191f;
  border-color: #14191f;
}
.daily-page .daily-send:hover:not(:disabled) {
  background: #0e7490;
  border-color: #0e7490;
}
.login-intro h1 { color: var(--yb-ink); }
.desktop-legal-links a { color: var(--yb-water); text-decoration: none; }
.desktop-legal-links a:hover { text-decoration: underline; }

/* ==========================================================================
   鱼摆摆 2.0 · 清冽海风工作室全局设计体系、暗夜主题与全套重构组件样式
   ========================================================================== */

/* 1. 用户原创 3D 小鱼摆摆形象与柔和动效（完整保留用户原图，严格服从减少动态开关） */
.yb-mascot-official {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: var(--yb-mascot-size, 56px);
  height: var(--yb-mascot-size, 56px);
  flex-shrink: 0;
  border-radius: 999px;
}
.yb-mascot-official .xiaoyu-pet,
.yb-mascot-official > img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.yb-mascot-official.yb-mascot-sunglass::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 999px;
  background: radial-gradient(circle, rgb(43 179 177 / 22%) 0%, rgb(43 179 177 / 0%) 72%);
  pointer-events: none;
  animation: yb-soft-pulse 3.2s ease-in-out infinite;
}
.yb-mascot-official.yb-mascot-bubble {
  animation: yb-float 3.6s ease-in-out infinite;
}
.yb-mascot-official:hover {
  transform: scale(1.04);
  transition: transform var(--yb-fast) var(--yb-ease);
}
@keyframes yb-soft-pulse {
  0%, 100% { transform: scale(.96); opacity: .7; }
  50% { transform: scale(1.06); opacity: 1; }
}

/* 2. 卡片统一 Stagger 渐入与交互态 */
@keyframes yb-card-enter {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.yb-stagger-item {
  animation: yb-card-enter .34s var(--yb-ease) both;
}

/* 3. 侧栏渐进底色开关（由设置 -> 界面实时切换） */
html[data-yb-sidebar-tint='on'] .reference-mode .ref-rail {
  background: linear-gradient(180deg, #e7f4f6 0%, #eff5f6 36%, #f4f5f6 100%);
}
html[data-yb-sidebar-tint='on'] .reference-mode .ref-sidebar,
html[data-yb-sidebar-tint='on'] .application > .sidebar {
  background: linear-gradient(180deg, #eff7f8 0%, #f7f9fa 32%, #ffffff 100%);
}
html[data-yb-sidebar-tint='off'] .reference-mode .ref-rail,
html[data-yb-sidebar-tint='off'] .reference-mode .ref-sidebar,
html[data-yb-sidebar-tint='off'] .application > .sidebar {
  background: var(--yb-paper);
}

/* 4. 深色模式全局设计令牌 */
html[data-yb-theme='dark'] {
  color-scheme: dark;
  --yb-ink: #eaf2f4;
  --yb-ink-2: #d3e1e5;
  --yb-ink-3: #b0c2c7;
  --yb-muted: #8ea3aa;
  --yb-faint: #677d84;
  --yb-line: #23333b;
  --yb-line-strong: #314752;
  --yb-canvas: #0e161a;
  --yb-paper: #142026;
  --yb-water: #2cb8be;
  --yb-water-2: #4bd1d5;
  --yb-water-soft: rgb(44 184 190 / 16%);
  --yb-water-mist: rgb(44 184 190 / 9%);
  --yb-shadow-1: 0 2px 6px rgb(0 0 0 / 28%);
  --yb-shadow-2: 0 10px 28px rgb(0 0 0 / 40%);
  --ink: var(--yb-ink);
  --muted: var(--yb-muted);
  --line: var(--yb-line);
}
html[data-yb-theme='dark'] body,
html[data-yb-theme='dark'] .application,
html[data-yb-theme='dark'] .app-workspace,
html[data-yb-theme='dark'] .reference-mode .ref-application > .app-workspace,
html[data-yb-theme='dark'] .reference-mode .ref-chat-shell > .social-main,
html[data-yb-theme='dark'] .main-content,
html[data-yb-theme='dark'] .ref-application .main-content,
html[data-yb-theme='dark'] .ref-task-page,
html[data-yb-theme='dark'] .yb-dual-shell,
html[data-yb-theme='dark'] .yb-main-pane,
html[data-yb-theme='dark'] .page-body,
html[data-yb-theme='dark'] .main-content .empty-state,
html[data-yb-theme='dark'] .ref-topbar,
html[data-yb-theme='dark'] .daily-chat,
html[data-yb-theme='dark'] .daily-composer,
html[data-yb-theme='dark'] .simple-creation-form,
html[data-yb-theme='dark'] .dlb-card,
html[data-yb-theme='dark'] .ds-shell,
html[data-yb-theme='dark'] dialog.yb-persona-dialog {
  background: var(--yb-paper) !important;
  color: var(--yb-ink) !important;
  border-color: var(--yb-line) !important;
}
html[data-yb-theme='dark'] .reference-mode .ref-application,
html[data-yb-theme='dark'] .reference-mode .social-app.ref-chat-shell {
  background: var(--yb-canvas) !important;
}
html[data-yb-theme='dark'] :where(h1, h2, h3, strong, .field-label, .ref-page-title) {
  color: var(--dark-heading-color, var(--yb-ink)) !important;
}
html[data-yb-theme='dark'] :where(p, small, .muted, .ds-card-desc, .ds-sub-label, .fc-card-desc) {
  color: var(--dark-detail-color, var(--yb-muted)) !important;
}
html[data-yb-theme='dark'] :where(:is(input:not([type=checkbox]):not([type=radio]), select, textarea):not(.yb-companion-pane *, .yb-persona-dialog *)) {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] :where(.ds-card, .ds-sub-tile, .ds-kpi-card, .fc-card, .dlb-card, .yb-team-member-card, .yb-orch-card, .yb-inspiration-chip, .login-panel) {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .ref-task-page .yb-companion-pane {
  --companion-surface: var(--wb-chrome);
  --companion-rule: var(--wb-line);
  --companion-ink: var(--wb-ink);
  --companion-muted: var(--wb-muted);
  --companion-accent: var(--wb-accent);
  --companion-hover: var(--wb-subtle);
  --companion-active: var(--wb-accent-soft);
  --companion-control: var(--wb-subtle);
}
html[data-yb-theme='dark'] :where(.welcome-banner, .ref-tabs, .ref-workspace-popover, .ref-attachment-menu, .ref-account-popover, .desktop-search-dialog, .yb-inspiration-tray) {
  background: var(--wb-chrome) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] :where(.yb-inspiration-btn, .ref-context-action, .ref-workspace-menu > summary, .ref-tab.active, .dlb-cat-btn.active, .ref-creation-shortcut) {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .yb-inspiration-btn:hover {
  border-color: var(--yb-water-2) !important;
  color: var(--wb-ink) !important;
}
html[data-yb-theme='dark'] :where(.button.secondary, .ref-account-option, .ref-attachment-option) {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink-2) !important;
}
html[data-yb-theme='dark'] :where(.button.quiet, .ref-header-action, .yb-companion-icon-btn) {
  color: var(--quiet-button-color, var(--yb-ink-2)) !important;
}
html[data-yb-theme='dark'] .ref-sidebar-item.active,
html[data-yb-theme='dark'] .ref-history-item.active {
  background: var(--wb-accent-soft) !important;
  color: #fff !important;
}

/* 5. 鱼摆摆 Apple HIG 双栏大管家工作区 · 自适应满高分栏与单行胶囊输入 */
.reference-mode .ref-application {
  grid-template-columns: 64px var(--ref-sidebar-width, 256px) minmax(0, 1fr);
}
html[data-ref-sidebar='closed'] .reference-mode .ref-application,
html[data-ref-sidebar='closed'] .reference-mode .social-app.ref-chat-shell {
  grid-template-columns: 64px 0 minmax(0, 1fr);
}
.reference-mode .ref-topbar {
  height: 46px;
  min-height: 46px;
  padding: 0 18px;
  background: rgb(255 255 255 / 80%);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid rgb(15 23 42 / 6%);
}
.yb-topbar-persona-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 2px 10px 2px 4px;
  border-radius: 999px;
  border: 1px solid rgb(15 23 42 / 8%);
  background: rgb(255 255 255 / 88%);
  color: var(--yb-ink);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color var(--yb-fast) var(--yb-ease), border-color var(--yb-fast) var(--yb-ease), transform 90ms ease;
}
.yb-topbar-persona-pill:hover {
  background: #f1f7f8;
  border-color: rgb(11 122 131 / 24%);
}
.yb-topbar-persona-pill:active { transform: scale(.97); }
.yb-topbar-persona-pill svg { color: var(--yb-muted); }

.ref-task-page {
  padding: 6px 18px 14px;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}
.ref-task-page .yb-dual-shell {
  display: grid;
  align-items: stretch;
  gap: 16px;
  height: 100%;
  min-height: 0;
  padding-bottom: 0;
}
.ref-task-page .daily-chat {
  min-height: 0 !important;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.ref-task-page .ref-task-empty {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  scrollbar-width: thin;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 8px 16px;
  margin: auto 0;
}
.ref-task-page .daily-compose-area {
  flex: 0 0 auto;
  width: 100%;
  max-width: 780px;
  margin: auto auto 0;
  padding: 4px 0 0;
}
.ref-task-context {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 30px;
  margin: 0 2px 6px;
  padding: 0 2px;
  font-size: 12.5px;
}
.ref-context-action,
.ref-workspace-menu > summary {
  font-size: 12.5px !important;
  gap: 5px;
  white-space: nowrap;
}
.ref-task-page:not(.ref-planning-open) .yb-dual-shell {
  grid-template-columns: minmax(0, 1fr);
}
.ref-task-page .yb-companion-pane {
  --companion-surface: #f7faf9;
  --companion-rule: #dfe8e5;
  --companion-ink: #182524;
  --companion-muted: #526361;
  --companion-accent: #23685b;
  --companion-hover: #eef4f2;
  --companion-active: #e6f1ee;
  --companion-control: var(--yb-paper);
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  align-self: stretch;
  border-radius: 16px;
  padding: 14px 12px;
  border: 1px solid var(--companion-rule);
  background: var(--companion-surface);
  color: var(--companion-ink);
  overflow: hidden;
  transition: transform var(--yb-mid) var(--yb-ease), opacity var(--yb-mid) var(--yb-ease);
}
.yb-companion-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  flex-shrink: 0;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--companion-rule);
}
.yb-companion-icon-btn {
  width: 28px;
  height: 32px;
  flex: none;
  border-radius: 8px;
  border: 0;
  background: transparent;
  color: var(--companion-muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.yb-companion-icon-btn:hover { background: var(--companion-hover); color: var(--companion-accent); }
.yb-companion-tabs {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  flex: 1;
  min-width: 0;
  align-items: center;
  border: 0;
  gap: 2px;
}
.yb-companion-tab {
  border: 0;
  background: transparent;
  min-height: 32px;
  padding: 4px 2px;
  border-radius: 8px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--companion-muted);
  cursor: pointer;
  transition: background-color var(--yb-fast) var(--yb-ease), color var(--yb-fast) var(--yb-ease), box-shadow var(--yb-fast) var(--yb-ease);
}
.yb-companion-tab.active {
  background: var(--companion-active);
  color: var(--companion-accent);
  font-weight: 600;
}
.yb-companion-tab:hover:not(.active) { background: var(--companion-hover); }
.yb-companion-pane :is(button, input, select, textarea):focus-visible { outline: 2px solid var(--companion-accent); outline-offset: 1px; }
.yb-companion-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 1px 2px 4px;
}
.yb-companion-body > [role='tabpanel'] { display: grid; align-content: start; gap: 14px; min-width: 0; }
.yb-companion-body > [role='tabpanel'][hidden] { display: none; }
.yb-companion-pane h2 { margin: 0; color: var(--companion-ink); font-size: 14px; line-height: 1.4; font-weight: 650; }
.ref-task-page .yb-companion-pane .daily-plan { display: grid; gap: 12px; padding: 2px 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.yb-companion-pane .daily-task-heading { display: flex; align-items: center; justify-content: space-between; min-height: 34px; gap: 8px; }
.yb-companion-pane .daily-task-heading input {
  width: 142px;
  min-width: 0;
  min-height: 34px;
  padding: 5px 8px;
  border: 1px solid var(--companion-rule);
  border-radius: 8px;
  background: var(--companion-control);
  color: var(--companion-ink);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.yb-companion-pane .daily-task-add {
  margin: 0;
  padding: 3px 4px 3px 10px;
  background: var(--companion-control);
  border: 1px solid var(--companion-rule);
  border-radius: 9px;
  box-shadow: none;
}
.yb-companion-pane .daily-task-add:focus-within { border-color: var(--companion-accent); }
.yb-companion-pane .daily-task-add input {
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--companion-ink);
  font-size: 13px;
  box-shadow: none;
}
.yb-companion-pane .daily-task-add input::placeholder { color: var(--companion-muted); }
.yb-companion-pane .daily-task-add input:focus-visible { outline: none; }
.yb-companion-pane .daily-task-add-button {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: var(--companion-active);
  border: 0;
  color: var(--companion-accent);
}
.yb-companion-pane .daily-task-add-button:hover:not(:disabled) { background: var(--companion-hover); }
.yb-companion-pane .daily-task-meta { display: flex; align-items: center; justify-content: space-between; min-height: 24px; gap: 8px; }
.yb-companion-pane .daily-task-count { margin: 0; color: var(--companion-muted); font-size: 12px; }
.yb-companion-pane .daily-task-list { margin: 0; padding: 0; list-style: none; }
.yb-companion-pane .daily-task-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 6px;
  padding: 8px 0;
  border-top: 1px solid var(--companion-rule);
  border-bottom: 0;
}
.yb-companion-pane .daily-task-row.editing { display: block; }
.yb-companion-pane .daily-task-check { align-items: start; gap: 8px; padding: 5px 0; color: var(--companion-ink); font-size: 13px; line-height: 1.55; }
.yb-companion-pane .daily-task-check input { accent-color: var(--companion-accent); margin-top: 3px; }
.yb-companion-pane .daily-task-row.done .daily-task-check span { color: var(--companion-muted); }
.yb-companion-pane .daily-task-actions { margin: 0; gap: 1px; }
.yb-companion-pane .daily-task-actions .button { min-height: 30px; padding: 3px 6px; color: var(--companion-muted); font-size: 12px; }
.yb-companion-pane .daily-task-edit { padding: 0; }
.yb-companion-pane .daily-task-edit input {
  min-height: 36px;
  border-color: var(--companion-rule);
  border-radius: 8px;
  background: var(--companion-control);
  color: var(--companion-ink);
  font-size: 13px;
}
.ref-task-page .daily-memory-card {
  background: transparent;
  border: 0;
  padding: 4px 2px 12px;
}
html[data-yb-theme='dark'] .ref-task-page .daily-memory-card { background: transparent !important; }
.daily-memory-status { display: flex; align-items: center; gap: 5px; margin: 8px 0 0; color: var(--companion-accent); font-size: 12px; }
.daily-memory-card .daily-preference-form { padding: 0; gap: 10px; }
.daily-memory-card .daily-preference-form .field { gap: 4px; }
.daily-memory-card .daily-preference-form :is(.field-label, .daily-small) { color: var(--companion-muted); font-size: 12px; }
.daily-memory-card .daily-preference-form .field input,
.daily-memory-card .daily-preference-form .field select,
.daily-memory-card .daily-preference-form .field textarea {
  min-height: 36px;
  padding: 7px 9px;
  border: 1px solid var(--companion-rule);
  border-radius: 8px;
  background: var(--companion-control);
  color: var(--companion-ink);
  font-size: 13px;
}
.daily-memory-card .daily-preference-actions { gap: 7px; }
.yb-persona-preview-box {
  display: grid;
  place-items: center;
  margin: 8px auto 14px;
}
.yb-companion-links h2 { padding: 3px 0 6px; }
.yb-companion-list-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 36px;
  padding: 7px 6px;
  border-radius: 8px;
  border: 0;
  background: transparent;
  color: var(--companion-ink);
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
.yb-companion-list-row:hover:not(:disabled) { background: var(--companion-hover); }
.yb-companion-list-row:has(svg:first-child) { justify-content: start; }
.yb-companion-list-row svg { flex: none; color: var(--companion-muted); }

/* 输入框上方悬浮「灵感」按钮与快填胶囊条 */
.yb-compose-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.yb-inspiration-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid rgb(15 23 42 / 9%);
  background: #fff;
  color: var(--yb-ink-2);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 1px 4px rgb(13 29 34 / 5%);
  transition: border-color var(--yb-fast) ease, color var(--yb-fast) ease, transform 90ms ease;
}
.yb-inspiration-btn:hover { border-color: var(--yb-water-2); color: var(--yb-water); transform: translateY(-1px); }
.yb-inspiration-tray {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  padding: 10px 12px;
  border-radius: 16px;
  background: var(--yb-water-mist);
  border: 1px solid rgb(11 122 131 / 14%);
  animation: yb-card-enter .22s var(--yb-ease);
}
.yb-inspiration-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid #dce5e9;
  background: #fff;
  color: var(--yb-ink-2);
  font-size: 12px;
  cursor: pointer;
}
.yb-inspiration-chip:hover { border-color: var(--yb-water); color: var(--yb-water); background: var(--yb-water-soft); }

/* 大管家应用智能编排执行卡 */
.yb-orch-card {
  margin-top: 12px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgb(11 122 131 / 20%);
  background: linear-gradient(135deg, #f3fafb 0%, #ffffff 100%);
  box-shadow: 0 8px 24px rgb(11 122 131 / 8%);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.yb-orch-step {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 13px;
  border-radius: 13px;
  border: 1px solid #e6edf0;
  background: #fff;
}
.yb-orch-step.is-done {
  border-color: rgb(11 122 131 / 32%);
  background: #f0faf8;
}
.yb-orch-step strong { display: block; font-size: 13.5px; color: var(--yb-ink); margin-bottom: 3px; }
.yb-orch-step small { display: block; font-size: 12px; color: var(--yb-muted); line-height: 1.5; }

/* 6. 自定义大管家弹窗 (`dialog.yb-persona-dialog`) */
dialog.yb-persona-dialog {
  width: min(460px, calc(100vw - 32px));
  background: #fff;
  color: var(--yb-ink);
  box-shadow: 0 24px 68px rgb(13 29 34 / 20%);
}
.yb-persona-poses {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 10px;
}
.yb-pose-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 9px 6px;
  border-radius: 14px;
  border: 1px solid #e3eaee;
  background: #fafcfd;
  cursor: pointer;
  font-size: 12px;
  color: var(--yb-muted);
}
.yb-pose-card.selected {
  border-color: var(--yb-water);
  background: var(--yb-water-soft);
  color: var(--yb-water);
  font-weight: 600;
}
.yb-trait-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}
.yb-trait-pill {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid #dfe6eb;
  background: #f6f8fa;
  color: var(--yb-ink-2);
  font-size: 13px;
  cursor: pointer;
}
.yb-trait-pill.selected {
  background: var(--yb-ink);
  border-color: var(--yb-ink);
  color: #fff;
}

/* 7. 多模型 AI 好友建队拉群 + 三大视频场景卡片 */
.yb-scenario-badge {
  display: inline-flex;
  align-self: flex-start;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: var(--yb-water-soft);
  color: var(--yb-water);
}
.yb-team-member-card {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid #e4eaef;
  background: #fafcfd;
}

/* 8. 应用中心 3 列 Squircle 矩阵 & 资源库二级导航 */
.dlb-shell {
  display: grid;
  grid-template-columns: 196px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
.dlb-cat-nav {
  position: sticky;
  top: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dlb-cat-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 13px;
  border-radius: 12px;
  border: 0;
  background: transparent;
  color: var(--yb-muted);
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
}
.dlb-cat-btn:hover { background: var(--yb-water-mist); color: var(--yb-ink); }
.dlb-cat-btn.active { background: #edf5f7; color: var(--yb-ink); font-weight: 600; }

/* 9. 设置弹窗升级：订阅余额卡 / 52周热力图 / 界面线框选择卡 */
.ds-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.ds-kpi-card {
  padding: 14px;
  border-radius: 15px;
  border: 1px solid #e6ecef;
  background: #fbfcfd;
}
.ds-kpi-card strong {
  display: block;
  font-size: 21px;
  font-weight: 700;
  margin: 4px 0 2px;
  font-variant-numeric: tabular-nums;
}
.ds-heatmap-card {
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid #e6ecef;
  background: #fff;
  margin-bottom: 14px;
}
.ds-heatmap-grid {
  display: grid;
  grid-template-columns: repeat(52, minmax(0, 1fr));
  grid-template-rows: repeat(7, 10px);
  grid-auto-flow: column;
  gap: 3px;
  margin-top: 10px;
  overflow-x: auto;
}
.ds-hm-cell {
  width: 10px;
  height: 10px;
  border-radius: 2.5px;
  background: #eef2f5;
}
.ds-hm-cell[data-level='1'] { background: #bfe8e5; }
.ds-hm-cell[data-level='2'] { background: #6fd0cc; }
.ds-hm-cell[data-level='3'] { background: #1e9fa3; }
.ds-hm-cell[data-level='4'] { background: #0a6b73; }
html[data-yb-theme='dark'] .ds-hm-cell { background: #213038; }
html[data-yb-theme='dark'] .ds-hm-cell[data-level='1'] { background: #184e54; }
html[data-yb-theme='dark'] .ds-hm-cell[data-level='2'] { background: #1f747b; }
html[data-yb-theme='dark'] .ds-hm-cell[data-level='3'] { background: #29a4a9; }
html[data-yb-theme='dark'] .ds-hm-cell[data-level='4'] { background: #5be0df; }

@media (max-width: 980px) {
  .dlb-shell { grid-template-columns: minmax(0, 1fr); }
  .ds-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .fc-grid-3, .dlb-sub-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 登录页与全站工作区清冽海风统一样式 + 深色模式全面兜底 ---------- */
.login-page {
  background: radial-gradient(circle at 18% 18%, #e4f4f6 0%, #f5f9fa 42%, #faf7f2 100%);
}
.login-page .login-panel {
  border: 1px solid rgb(13 29 34 / 7%);
  border-radius: 26px;
  box-shadow: 0 18px 54px rgb(13 29 34 / 9%);
}
.login-page .login-submit {
  background: linear-gradient(135deg, #0b7a83 0%, #155c67 100%);
  border-color: #0b7a83;
  border-radius: 14px;
}
.login-page .login-submit:hover {
  background: linear-gradient(135deg, #0d8d97 0%, #196d7a 100%);
}


/* 群聊、多模型工作区、视频工作流、爆款复刻、账号模型、企业与经营页面统一卡片圆角与深色适配 */
.video-flow-intake,
.video-flow-stage,
.viral-link-card,
.viral-upload-card,
.viral-parsed,
.viral-result > section,
.viral-result-head,
.enterprise-section,
.agent-room-page .room-card,
.accounts-page .account-source-option {
  border-radius: 18px;
  transition: border-color var(--yb-fast) var(--yb-ease), box-shadow var(--yb-mid) var(--yb-ease), transform var(--yb-fast) var(--yb-ease);
}

html[data-yb-theme='dark'] :where(
  .social-sidebar,
  .social-rail,
  .social-details,
  .social-composer,
  .social-modal,
  .video-flow-intake,
  .video-flow-stage,
  .video-flow-context,
  .video-flow-quick-upload,
  .viral-link-card,
  .viral-upload-card,
  .viral-parsed,
  .viral-result > section,
  .viral-result-head,
  .viral-file-row,
  .accounts-page .account-source-option,
  .agent-room-page .room-start,
  .agent-room-page .room-members li,
  .enterprise-section,
  .enterprise-member,
  .dlb-rail,
  .daily-preferences,
  .daily-aside-note,
  .business-home,
  .business-task
) {
  background-color: #142026 !important;
  border-color: var(--yb-line) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .social-modal-backdrop {
  background: rgb(8 14 18 / 64%);
}
html[data-yb-theme='dark'] .yb-topbar-persona-pill {
  background: #18272f !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] :where(.social-room:hover, .social-room.active, .accounts-page .account-source-option.active, .social-search) {
  background-color: #1c2c34 !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] :where(
  .social-bubble,
  .social-message-card,
  .room-chat-entry,
  .dlb-prompt-card,
  .yb-orch-step,
  .yb-pose-card,
  .yb-trait-pill,
  .viral-samples-card,
  .viral-sample-item,
  .main-content .project-list,
  .main-content .project-list-row
) {
  background-color: #18272f !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .yb-orch-step strong,
html[data-yb-theme='dark'] .viral-sample-item h3 {
  color: #eef6f8 !important;
}
html[data-yb-theme='dark'] .yb-orch-step small,
html[data-yb-theme='dark'] .viral-sample-item p {
  color: #9fb4bd !important;
}
html[data-yb-theme='dark'] .yb-orch-step.is-done,
html[data-yb-theme='dark'] .yb-pose-card.selected,
html[data-yb-theme='dark'] .yb-trait-pill.active,
html[data-yb-theme='dark'] .viral-sample-item.selected {
  background-color: #133139 !important;
  border-color: var(--yb-water-2) !important;
  color: #ffffff !important;
}
html[data-yb-theme='dark'] .main-content .project-list-row:hover {
  background-color: #1f333d !important;
}
html[data-yb-theme='dark'] .ref-search {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .ref-search-input {
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .ref-sidebar-action {
  --sidebar-action-color: var(--yb-ink);
  --sidebar-action-hover: var(--wb-subtle);
  --sidebar-action-icon: var(--wb-muted);
  color: var(--sidebar-action-color);
}
html[data-yb-theme='dark'] .ref-sidebar-action svg {
  color: var(--sidebar-action-icon);
}
html[data-yb-theme='dark'] .ref-sidebar-action:hover {
  background: var(--sidebar-action-hover);
}
html[data-yb-theme='dark'] .ref-sidebar-action.active {
  background: var(--wb-accent-soft);
  --sidebar-action-color: var(--wb-ink);
  color: var(--sidebar-action-color);
}
html[data-yb-theme='dark'] .ref-history-copy strong,
html[data-yb-theme='dark'] .ref-sidebar .social-room-title strong {
  color: var(--wb-ink) !important;
}
html[data-yb-theme='dark'] .ref-history-copy small,
html[data-yb-theme='dark'] .ref-sidebar .social-room-preview,
html[data-yb-theme='dark'] .ref-list-label {
  color: var(--yb-muted) !important;
}
html[data-yb-theme='dark'] .ref-sidebar .social-room:hover:not(.active),
html[data-yb-theme='dark'] .ref-history-item:hover:not(.active) {
  background: var(--wb-subtle) !important;
}
html[data-yb-theme='dark'] .ref-sidebar .social-room.active,
html[data-yb-theme='dark'] .ref-history-item.active {
  background: var(--wb-accent-soft) !important;
}

/* ---------- Apple HIG 最高规格交互、排版与全页面视觉统一精修 ---------- */
html, body, .reference-mode {
  font-family: 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-synthesis: weight style;
  -webkit-font-smoothing: auto;
  text-rendering: auto;
}
:where(.main-content, .page-body, .dlb-shell, .simple-creation-page, .accounts-page, .enterprise-page, .operations-page, .business-page, .ref-sidebar-scroll, .social-messages) {
  scrollbar-width: thin;
  scrollbar-color: rgb(15 23 42 / 16%) transparent;
  scroll-behavior: smooth;
}

/* 1. 短视口 (1280x620 / 笔记本150%缩放) 自适应安全边界，确保主页零裁切 */
@media (max-height: 700px) {
  .ref-task-page .ref-task-empty { padding: 4px 12px; }
  .ref-task-page .ref-task-welcome-mark { transform: scale(.82); margin-bottom: -8px; }
  .ref-task-page .ref-task-empty h1 { font-size: 24px; margin: 4px 0 4px; line-height: 1.3; }
  .ref-task-page .yb-companion-head { margin-bottom: 8px; }
  .ref-sidebar { padding: 12px 10px 10px; }
  .ref-sidebar .ref-sidebar-action { min-height: 34px; padding: 5px 10px; font-size: 13.5px; }
}
@media (max-height: 600px) {
  .ref-task-page .ref-task-welcome-mark { display: none; }
}

/* 2. 全站工作区首屏紧致排版与卡片 Apple 层级 */
.reference-mode .main-content > .page-body,
.reference-mode .main-content > .desktop-library {
  padding-top: 20px !important;
  padding-bottom: 36px !important;
}
/* 3. 视频导演 & 爆款仿作：Apple Segmented 模式切换与三大场景卡 */
.video-mode-tab {
  transition: background-color .16s ease, box-shadow .16s ease, color .16s ease !important;
}

/* 5. 资源库：Apple 分段筛选条与精雕卡片 */
.dlb-toolbar {
  padding-bottom: 12px;
}
.dlb-tabs {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px;
  border-radius: 12px;
  background: #eff2f5;
  border: 1px solid rgb(15 23 42 / 5%);
}
.dlb-tab {
  border: 0;
  padding: 6px 13px;
  min-height: 30px;
  font-size: 12.5px;
  font-weight: 500;
  color: #525d69;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.dlb-tab:hover:not(.selected) {
  background: rgb(255 255 255 / 60%);
  color: #1e293b;
}
.dlb-tab.selected {
  font-weight: 600;
}
.dlb-sub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}

/* 6. 企业账户、经营助手 */
.enterprise-section {
  background: #fff;
  margin-bottom: 14px;
  box-shadow: 0 1px 4px rgb(15 23 42 / 3%);
}
.product-thumb-placeholder {
  border-radius: 12px;
  background: linear-gradient(135deg, #f1f5f8 0%, #e7eef2 100%);
  border: 1px solid rgb(15 23 42 / 6%);
  color: #64748b;
  font-weight: 500;
}

/* 7. 群聊主页、空态与全站弹窗 Apple Sheet 规范 (弹性滚屏+Sticky Footer防裁切) */
.ref-empty-topbar {
  height: 46px;
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  border-bottom: 1px solid rgb(15 23 42 / 6%);
  background: rgb(255 255 255 / 78%);
  backdrop-filter: saturate(180%) blur(18px);
}
.social-empty-chat {
  padding: 28px 24px !important;
  gap: 10px;
}
.social-empty-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
}
.social-modal-backdrop {
  background: rgb(17 32 34 / 32%);
  backdrop-filter: none;
}
.social-modal {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-height: min(90dvh, 720px);
  border-radius: 20px;
  border: 1px solid rgb(15 23 42 / 8%);
  padding: 0;
  box-shadow: 0 24px 64px -12px rgb(15 23 42 / 22%);
  animation: yb-dialog-in 150ms ease-out;
}
.social-modal > header {
  flex: none;
  padding: 16px 22px 13px;
  margin: 0;
  border-bottom: 1px solid rgb(15 23 42 / 7%);
  background: rgb(255 255 255 / 92%);
}
.social-modal > :not(header) {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px 22px 18px;
}
.social-modal > form.social-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 22px 0;
}
.social-modal-sticky-foot {
  position: sticky;
  bottom: 0;
  z-index: 4;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: 6px -22px 0;
  padding: 12px 22px 16px;
  border-top: 1px solid rgb(15 23 42 / 7%);
  background: linear-gradient(180deg, rgb(255 255 255 / 88%) 0%, #ffffff 34%);
  backdrop-filter: blur(12px);
}
.yb-team-head-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: end;
}
.yb-team-autocreate-check {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  font-size: 13px;
  color: #334155;
  white-space: nowrap;
  cursor: pointer;
}
.yb-team-members-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.yb-persona-dialog {
  max-height: min(88dvh, 660px);
  overflow-y: auto;
  border-radius: 20px;
  padding: 20px 22px;
  border: 1px solid rgb(15 23 42 / 8%);
}
.yb-persona-dialog input:not([type='checkbox']):not([type='radio']),
.yb-persona-dialog textarea {
  display: block;
  width: 100%;
  box-sizing: border-box;
  border-radius: 11px;
  border: 1px solid #d5dfe6;
  padding: 9px 12px;
  font-size: 13.5px;
  line-height: 1.5;
  background: #fbfcfd;
  color: #0f172a;
  transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}
.yb-persona-dialog textarea { --field-focus-border: #0b7a83; }
.yb-persona-dialog input:not([type='checkbox']):not([type='radio']):focus,
.yb-persona-dialog textarea:focus {
  outline: none;
  background: #fff;
  box-shadow: 0 0 0 3px rgb(11 122 131 / 14%);
}
dialog:focus { outline: none; }
html[data-yb-theme='dark'] .dlb-tabs {
  background: #101a20;
  border-color: var(--yb-line);
}
html[data-yb-theme='dark'] .dlb-tab.selected {
  background: #1b2f38;
  color: #ffffff;
  border-color: var(--yb-line-strong);
}
html[data-yb-theme='dark'] .social-modal > header,
html[data-yb-theme='dark'] .social-modal-sticky-foot {
  background: rgb(20 32 38 / 94%) !important;
  border-color: var(--yb-line) !important;
}
html[data-yb-theme='dark'] .yb-persona-dialog input:not([type='checkbox']):not([type='radio']),
html[data-yb-theme='dark'] .yb-persona-dialog textarea {
  background: #142229;
  border-color: var(--yb-line-strong);
  color: #eef5f7;
}
html[data-yb-theme='dark'] .yb-persona-dialog textarea { --field-focus-border: var(--yb-line-strong); }
html[data-yb-theme='dark'] .ref-empty-topbar {
  background: rgb(16 26 32 / 86%);
  border-color: var(--yb-line);
}

html[data-yb-theme='dark'] .simple-creation-page .segment {
  --creation-segment-fill: #15232a;
  --creation-segment-line: var(--yb-line-strong);
  --creation-segment-ink: var(--yb-ink);
  background: var(--creation-segment-fill);
  border-color: var(--creation-segment-line);
  color: var(--creation-segment-ink);
}
html[data-yb-theme='dark'] .simple-creation-page .segment::before {
  background: #101a20;
  border-color: #46606d;
}
html[data-yb-theme='dark'] .simple-creation-page .segment.selected {
  --creation-segment-fill: #133139;
  --creation-segment-line: #2cb8be;
  --creation-segment-ink: #ffffff;
}
html[data-yb-theme='dark'] .simple-creation-page .segment.selected::before {
  background: #2cb8be;
  border-color: #2cb8be;
  box-shadow: inset 0 0 0 3.5px #101a20;
}
html[data-yb-theme='dark'] .ref-task-page .daily-send {
  background: #2cb8be !important;
  color: #081519 !important;
}
html[data-yb-theme='dark'] .ref-task-page .daily-send:disabled {
  background: #233640 !important;
  color: #7c96a1 !important;
}
html[data-yb-theme='dark'] .model-picker-menu-footer {
  background: #111d23;
  border-top-color: #23343d;
}
html[data-yb-theme='dark'] .model-picker-filter {
  background: #1b2c35;
  color: #9bb1ba;
}
html[data-yb-theme='dark'] .model-picker-filter.active {
  background: #24404c;
  color: #ffffff;
}
html[data-yb-theme='dark'] .product-thumb-placeholder {
  background: #192931;
  border-color: #2b414c;
  color: #93a9b1;
}
html[data-yb-theme='dark'] .yb-team-autocreate-check,
html[data-yb-theme='dark'] .ref-tone-menu > summary {
  color: #c2d4da !important;
}
html[data-yb-theme='dark'] .button.primary {
  background: #2cb8be !important;
  color: #081519 !important;
}
html[data-yb-theme='dark'] .button.primary:disabled {
  background: #1c2e36 !important;
  color: #8ba3ad !important;
}

/* 9. 用量分段槽与深色模式全局残留白块/分割线清零 */
.ds-usage-range-track {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border-radius: 12px;
  background: #f2f5f7;
  border: 1px solid #e4eaef;
}
.ds-usage-range-track.compact {
  border-radius: 10px;
}
html[data-yb-theme='dark'] .ds-usage-range-track {
  background: #101a20;
  border-color: #23343d;
}
html[data-yb-theme='dark'] .ds-usage-range-track > .button.quiet {
  --quiet-button-color: #a9c0c8;
}
html[data-yb-theme='dark'] .ds-usage-range-track > .button.quiet:hover:not(:disabled) {
  background: #192a33;
  --quiet-button-color: #ffffff;
}
/* 左下角账号徽章与无模型引导横条 */
html[data-yb-theme='dark'] .ref-account-avatar {
  background: #182a33 !important;
  border-color: #2f4957 !important;
  color: #e2f2f5 !important;
}
html[data-yb-theme='dark'] .ref-account-option:hover {
  background: #1d323d !important;
  color: #ffffff !important;
}
html[data-yb-theme='dark'] .ref-task-page .daily-model-empty,
html[data-yb-theme='dark'] .daily-model-empty {
  background: #142229 !important;
  border: 1px solid #243742 !important;
  color: #a9c0c8 !important;
}
html[data-yb-theme='dark'] .ref-task-page .daily-model-empty .button,
html[data-yb-theme='dark'] .daily-model-empty .button {
  background: #1b333e !important;
  border: 1px solid #2e515e !important;
  color: #7ee7eb !important;
}

/* 商品图片与视频简版流程页暗夜全景适配 */
html[data-yb-theme='dark'] .simple-creation-page .simple-creation-form {
  background: transparent !important;
  border-color: var(--yb-line) !important;
}
html[data-yb-theme='dark'] .simple-poster-progress {
  border-bottom-color: #23343d;
}
html[data-yb-theme='dark'] .simple-poster-progress > li {
  color: #93aab3;
}
html[data-yb-theme='dark'] .simple-poster-step {
  background: #192a33;
  color: #b7ccd3;
}
html[data-yb-theme='dark'] .simple-poster-progress > .current {
  color: #7dd3fc;
}
html[data-yb-theme='dark'] .simple-poster-progress > .current .simple-poster-step {
  background: #153549;
  color: #8ce0ff;
}
html[data-yb-theme='dark'] .simple-poster-progress > .done {
  color: #5eead4;
}
html[data-yb-theme='dark'] .simple-poster-progress > .done .simple-poster-step {
  background: #133935;
  color: #5eead4;
}
html[data-yb-theme='dark'] .simple-creation-page .segmented,
html[data-yb-theme='dark'] .segmented {
  --creation-segment-track-fill: #101b21;
  background: var(--creation-segment-track-fill);
  --creation-segment-track-line: #23343d;
  border: 1px solid var(--creation-segment-track-line);
}
html[data-yb-theme='dark'] .simple-creation-page .simple-source-guidance,
html[data-yb-theme='dark'] .simple-creation-page .simple-note,
html[data-yb-theme='dark'] .simple-creation-page .simple-multiselect summary span,
html[data-yb-theme='dark'] .simple-creation-page .simple-more > summary > span,
html[data-yb-theme='dark'] .simple-creation-page summary {
  color: #9bb1ba !important;
}
html[data-yb-theme='dark'] .simple-poster-page .simple-text-mode strong {
  color: #edf5f7 !important;
}
html[data-yb-theme='dark'] .simple-poster-page .simple-text-mode small {
  color: #93a9b1 !important;
}
html[data-yb-theme='dark'] .saved-asset-chip {
  background: #192b34;
  border-color: #2c414d;
  color: #e0eef2;
}
html[data-yb-theme='dark'] .saved-asset-chip:hover {
  background: #203642;
  border-color: #2cb8be;
}
html[data-yb-theme='dark'] .saved-asset-chip.selected {
  background: #14363f;
  border-color: #2cb8be;
  box-shadow: 0 0 0 1px #2cb8be;
  color: #ffffff;
}

/* 视频模式栏、账户连接页与通用徽标/提示框暗夜补全 */
html[data-yb-theme='dark'] .video-mode-tab:not(.active) {
  background: #15232b;
  border-color: #263943;
  color: #d6e6eb;
}
html[data-yb-theme='dark'] .video-mode-tab:not(.active):hover {
  background: #1b2f38;
  border-color: #365260;
}
html[data-yb-theme='dark'] .accounts-page .account-connection-guide,
html[data-yb-theme='dark'] .accounts-page .account-current-selection,
html[data-yb-theme='dark'] .accounts-page .account-optional-test,
html[data-yb-theme='dark'] .accounts-page .account-fallback,
html[data-yb-theme='dark'] .accounts-page .account-usage-overview > .account-wallet,
html[data-yb-theme='dark'] .notice {
  background: #142229 !important;
  border-color: #243742 !important;
  color: #c8dce2 !important;
}
html[data-yb-theme='dark'] .accounts-page .account-workspace-tab {
  background: #15232b;
  border-color: #263943;
  color: #b4c9d0;
}
html[data-yb-theme='dark'] .accounts-page .account-workspace-tab.active {
  background: #193540 !important;
  border-color: #2cb8be !important;
  color: #ffffff;
}
html[data-yb-theme='dark'] .tag {
  background: #192b34;
  --dark-detail-color: #b8cdd4;
  color: var(--dark-detail-color);
  border-color: #293e4a;
}
html[data-yb-theme='dark'] .tag.accent {
  background: #14363d;
  --dark-detail-color: #79e7ea;
  color: var(--dark-detail-color);
}
html[data-yb-theme='dark'] .accounts-page .edition-explanation,
html[data-yb-theme='dark'] .edition-explanation,
html[data-yb-theme='dark'] .accounts-page .account-deployment-note {
  background: #142229;
  border: 1px solid #23343d;
  border-radius: 14px;
  padding: 6px 14px;
  color: #b4c9d0;
}
html[data-yb-theme='dark'] .accounts-page .account-deployment-note summary,
html[data-yb-theme='dark'] .edition-explanation > summary {
  --details-summary-hover: transparent;
  color: #b4c9d0;
  background: transparent;
}
html[data-yb-theme='dark'] .accounts-page .account-workspace-tabs {
  border-bottom-color: #23343d;
}
html[data-yb-theme='dark'] .accounts-page .account-source-option.active {
  background: #16333c;
  border-color: #2cb8be;
}
html[data-yb-theme='dark'] .accounts-page :where(
  .account-wallet,
  .account-test,
  .account-source-notice,
  .account-connection,
  .account-runtime-tool,
  .account-runtime,
  .account-membership-limits,
  .account-connect,
  .account-connect-step,
  .account-connect-component,
  .account-connect-identity,
  .account-connect-summary,
  .account-trial-details
) {
  background: #15232b !important;
  border-color: #243742 !important;
  color: #d6e6eb !important;
}
html[data-yb-theme='dark'] .accounts-page .account-wallet-funding-details,
html[data-yb-theme='dark'] .accounts-page .account-detail,
html[data-yb-theme='dark'] .accounts-page .account-usage,
html[data-yb-theme='dark'] .accounts-page .account-usage-row {
  border-color: #23343d !important;
}
html[data-yb-theme='dark'] .accounts-page .account-wallet-value {
  color: #f0f7f9;
}

/* ---------- 减少动态效果 ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after, dialog[open]::backdrop { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
}
html[data-motion='off'] *, html[data-motion='off'] *::before, html[data-motion='off'] *::after, html[data-motion='off'] dialog[open]::backdrop {
  animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important;
}

/* ---------- 多模型群聊 2.0 夜间护眼夜海岩蓝全组件适配 ---------- */
html[data-yb-theme='dark'] .social-group-pane {
  background: #101b21 !important;
  border-right-color: var(--yb-line);
  color: var(--yb-ink);
}
html[data-yb-theme='dark'] .social-group-pane-head {
  border-bottom-color: var(--yb-line);
}
html[data-yb-theme='dark'] .social-group-pane-head strong,
html[data-yb-theme='dark'] .social-group-info-copy h2,
html[data-yb-theme='dark'] .social-group-info-section h3 {
  color: #f0f7f9 !important;
}
html[data-yb-theme='dark'] .social-topic-chip {
  background: #16242c;
  border-color: var(--yb-line-strong);
  color: #cce0e6;
}
html[data-yb-theme='dark'] .social-topic-chip:hover {
  background: #1c2e38;
  border-color: #2c6d75;
}
html[data-yb-theme='dark'] .social-pane-agent {
  color: #d6e7ec;
}
html[data-yb-theme='dark'] .social-pane-agent:hover:not(:disabled) {
  background: #172730;
}
html[data-yb-theme='dark'] .social-pane-agent.mentioned {
  background: #16343d;
  border-color: #2aa7ad;
}
html[data-yb-theme='dark'] .social-pane-agent-copy small,
html[data-yb-theme='dark'] .social-pane-agent time,
html[data-yb-theme='dark'] .social-group-pane-title,
html[data-yb-theme='dark'] .social-group-pane-empty,
html[data-yb-theme='dark'] .social-group-info-copy p {
  color: #8fa9b3 !important;
}
html[data-yb-theme='dark'] .social-apps-popover {
  background: #15242c;
  border-color: var(--yb-line-strong);
  color: var(--yb-ink);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .55);
}
html[data-yb-theme='dark'] .social-apps-head {
  border-bottom-color: var(--yb-line);
}
html[data-yb-theme='dark'] .social-apps-item:hover {
  background: #1c2f39;
}
html[data-yb-theme='dark'] .social-listen-toggle.all {
  background: #13342c;
  border-color: #215b4b !important;
  color: #7ee2be;
}
html[data-yb-theme='dark'] .social-listen-toggle.all:hover:not(:disabled) {
  background: #184237;
}
html[data-yb-theme='dark'] .social-listen-toggle.passive {
  background: #312516;
  border-color: #634924 !important;
  color: #f3c478;
}
html[data-yb-theme='dark'] .social-listen-toggle.passive:hover:not(:disabled) {
  background: #3d2e1b;
}
html[data-yb-theme='dark'] .social-avatar.group {
  --social-avatar-theme-background: linear-gradient(145deg, #1b313d, #152731);
  background: var(--social-avatar-theme-background);
  border-color: #2a4757;
  color: #8ee5ea;
}
html[data-yb-theme='dark'] .social-avatar.social-tone-sage {
  --social-avatar-theme-background: linear-gradient(145deg, #173a32, #122d26);
  background: var(--social-avatar-theme-background);
  color: #7be2c2;
}
html[data-yb-theme='dark'] .social-avatar.social-tone-amber {
  --social-avatar-theme-background: linear-gradient(145deg, #3c2c18, #2d2011);
  background: var(--social-avatar-theme-background);
  color: #f6c879;
}
html[data-yb-theme='dark'] .social-avatar.social-tone-blue {
  --social-avatar-theme-background: linear-gradient(145deg, #192f4a, #132439);
  background: var(--social-avatar-theme-background);
  color: #89bfff;
}
html[data-yb-theme='dark'] .social-avatar.social-tone-rose {
  --social-avatar-theme-background: linear-gradient(145deg, #3e1f2b, #2f1720);
  background: var(--social-avatar-theme-background);
  color: #f39bb5;
}
html[data-yb-theme='dark'] .social-avatar.social-tone-slate {
  --social-avatar-theme-background: linear-gradient(145deg, #212c36, #182129);
  background: var(--social-avatar-theme-background);
  color: #c4d5e0;
}
html[data-yb-theme='dark'] .social-chat,
html[data-yb-theme='dark'] .social-chat-center,
html[data-yb-theme='dark'] .social-chat-stage,
html[data-yb-theme='dark'] .social-chat-body,
html[data-yb-theme='dark'] .social-message-scroll,
html[data-yb-theme='dark'] .social-message-list,
html[data-yb-theme='dark'] .social-composer-area,
html[data-yb-theme='dark'] .social-empty-chat,
html[data-yb-theme='dark'] .social-group-info {
  background: var(--yb-paper) !important;
  background-color: var(--yb-paper) !important;
  color: var(--yb-ink) !important;
}
html[data-yb-theme='dark'] .social-member-group-title h4,
html[data-yb-theme='dark'] .social-member-group-title span,
html[data-yb-theme='dark'] .social-member-subhead,
html[data-yb-theme='dark'] .social-details-head h3 {
  color: #cfe2e9 !important;
}
html[data-yb-theme='dark'] .social-no-messages,
html[data-yb-theme='dark'] .social-composer-note {
  color: #8fa9b3 !important;
}
html[data-yb-theme='dark'] .social-task-shortcut {
  color: #9cb4be;
}
html[data-yb-theme='dark'] .social-task-shortcut:hover:not(:disabled) {
  background: #1a2c35;
  color: #ffffff;
}
html[data-yb-theme='dark'] .social-composer-model {
  background: var(--wb-subtle) !important;
  border-color: var(--yb-line-strong) !important;
  color: var(--wb-ink) !important;
}

/* ===== 日常对话双边分列气泡 + 智能贴底与回底胶囊 ===== */
.ref-task-page .daily-chat {
  position: relative;
}
.ref-task-page .daily-messages {
  max-width: 820px;
  padding: 18px 18px 20px;
  gap: 20px;
  scroll-padding-bottom: 20px;
}
.daily-message {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.daily-message.user {
  align-items: flex-end;
}
.daily-message-label {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 6px;
  font-size: 12px;
  color: var(--yb-muted);
}
.daily-message.user .daily-message-label {
  flex-direction: row-reverse;
  justify-content: flex-start;
  margin-right: 2px;
}
.daily-message-label strong {
  font-weight: 600;
  color: var(--yb-ink-soft);
}
.daily-message.assistant .daily-message-text {
  margin: 0 0 0 34px;
  padding: 12px 16px;
  width: fit-content;
  max-width: min(82%, 650px);
  border-radius: 6px 18px 18px 18px;
  background: #f6f8fa;
  border: 1px solid #e5ecf1;
  color: #1c242d;
  font-size: 14.5px;
  line-height: 1.82;
  box-shadow: 0 1px 4px rgb(15 23 42 / 3%);
}
.daily-message.user .daily-message-text {
  margin: 0 30px 0 0;
  padding: 11px 16px;
  width: fit-content;
  max-width: min(76%, 560px);
  border-radius: 18px 6px 18px 18px;
  background: linear-gradient(180deg, #e7f4f7 0%, #ddf0f4 100%);
  border: 1px solid #c6e2ea;
  color: #0e242d;
  font-size: 14.5px;
  line-height: 1.75;
  box-shadow: 0 2px 10px rgb(11 122 131 / 6%);
  text-align: left;
}
.daily-message.optimistic .daily-message-text {
  opacity: .94;
}
.daily-orchestrations {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.daily-messages > .daily-progress {
  margin: 4px 0 6px 34px;
  padding: 10px 14px;
  width: fit-content;
  border-radius: 14px;
  background: #f4f9fa;
  border: 1px solid #dfeef1;
}
.daily-scroll-anchor {
  position: relative;
  flex: 0 0 auto;
  height: 0;
  width: 100%;
  max-width: 820px;
  margin-inline: auto;
  pointer-events: none;
  z-index: 12;
}
.daily-scroll-latest {
  position: absolute;
  right: 18px;
  bottom: 10px;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid #d4e3e8;
  background: rgb(255 255 255 / 92%);
  backdrop-filter: blur(12px);
  color: #0b6d77;
  font-size: 12px;
  font-weight: 600;
  box-shadow: 0 6px 20px rgb(15 23 42 / 10%);
  cursor: pointer;
  transition: transform 140ms var(--yb-ease), background-color 140ms ease, box-shadow 140ms ease;
}
.daily-scroll-latest svg {
  transform: rotate(90deg);
}
.daily-scroll-latest:hover {
  transform: translateY(-1px);
  background: #f0f9fa;
  box-shadow: 0 8px 24px rgb(11 122 131 / 14%);
}
.daily-scroll-latest[hidden] {
  display: none;
}
@media (max-width: 760px) {
  .ref-task-page .daily-messages { padding: 14px 6px 14px; gap: 16px; }
  .daily-message.assistant .daily-message-text { margin-left: 10px; max-width: 88%; }
  .daily-message.user .daily-message-text { margin-right: 8px; max-width: 86%; }
  .daily-receipt,
  .daily-messages > .daily-progress { margin-left: 10px; padding-left: 2px; }
}

/* 暗黑模式日常对话气泡与滚动胶囊 */
html[data-yb-theme='dark'] .daily-message-label strong {
  color: #d6e8ee !important;
}
html[data-yb-theme='dark'] .daily-scroll-latest {
  background: rgb(22 39 48 / 92%);
  border-color: #295060;
  color: #7ee3e9;
  box-shadow: 0 8px 24px rgb(0 0 0 / 34%);
}
html[data-yb-theme='dark'] .daily-scroll-latest:hover {
  background: #1b3642;
  color: #ffffff;
}

.ref-task-page .daily-chat.has-feed > .daily-chat-heading {
  flex-direction: row;
  align-items: center;
  min-height: 42px;
  gap: 10px;
  border-bottom: 1px solid var(--yb-line);
}
.ref-task-page .daily-chat.has-feed .daily-chat-heading h2 {
  margin: 0;
  font-size: 15px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.ref-task-page .daily-chat > .daily-messages {
  gap: 19px;
  padding: 18px 6px 16px;
}
.daily-message-content {
  display: flex;
  align-items: flex-end;
  gap: 9px;
  min-width: 0;
  max-width: 100%;
}
.daily-chat .daily-message.user .daily-message-content {
  max-width: min(84%, 580px);
}
.daily-chat .daily-message.assistant .daily-message-text {
  margin: 0;
  max-width: min(100% - 38px, 640px);
}
.daily-chat .daily-message.user .daily-message-text {
  margin: 0;
  max-width: 100%;
  min-width: 0;
}
.daily-chat .daily-message-content :is(.daily-user-dot, .daily-message-avatar) { flex: none; }
.daily-chat .daily-message-body { white-space: pre-wrap; }
.daily-chat .daily-message-text .workbench-chat-meta { margin-top: 4px; }
.daily-reply-state {
  align-self: flex-end;
  display: flex;
  gap: 5px 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  max-width: min(100%, 495px);
  margin-top: 6px;
  color: var(--yb-muted);
  font-size: 12px;
  line-height: 1.55;
}
.daily-reply-state-copy {
  display: flex;
  flex-wrap: wrap;
  column-gap: 7px;
}
.daily-reply-state-copy strong { color: var(--yb-ink-soft); }
.daily-reply-state :is(.button, summary) {
  min-height: 30px;
  padding: 4px 7px;
  color: var(--yb-water);
  font-size: inherit;
  cursor: pointer;
}
.daily-reply-details p { margin: 3px 0 0; overflow-wrap: anywhere; }
.ref-home-workspace .ref-task-page .daily-chat .ref-task-context {
  margin: 0 0 4px;
  padding: 0 4px;
  min-height: 30px;
  background: transparent;
}
@media (max-width: 520px) {
  .daily-reply-state { justify-content: flex-start; }
  .ref-task-page .daily-chat > .daily-messages { padding-inline: 3px; }
}

/* ==========================================================================
 * Uiverse Galaxy × Awesome-Design-MD 旗舰微交互与精密触感组件层
 * 融合 Linear / Apple HIG 1px 镜面发丝高光与 Uiverse 流光、聚光灯追随、悬浮输入舱
 * ========================================================================== */

/* 1. 光学等宽数字对齐（Awesome-Design-MD 规范） */
:where(
  [data-daily-task-count],
  .daily-receipt,
  .social-message-meta,
  .account-usage-row,
  .cost-result,
  .simple-fee,
  .xiaoyu-concierge-fee strong
) {
  font-variant-numeric: tabular-nums;
}

/* 2. Uiverse Galaxy 镜面扫光主按钮与发送键 */
:where(
  .button.primary,
  .ref-task-page .daily-send,
  .social-send,
  .chat-layout .send-button,
  .simple-creation-page .simple-submit
) {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 26%),
    inset 0 -1.5px 0 rgb(0 0 0 / 22%),
    0 2px 6px rgb(13 29 34 / 14%),
    0 8px 20px -4px rgb(11 122 131 / 22%);
  transition:
    transform 160ms var(--yb-ease),
    box-shadow 240ms var(--yb-ease),
    background-color 180ms var(--yb-ease),
    border-color 180ms var(--yb-ease);
}
:where(
  .button.primary,
  .simple-creation-page .simple-submit
)::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(112deg, transparent 28%, rgb(255 255 255 / 28%) 50%, transparent 72%);
  transform: translateX(-130%);
  transition: transform 620ms var(--yb-ease);
}
:where(
  .button.primary,
  .simple-creation-page .simple-submit
):hover:not(:disabled)::after {
  transform: translateX(130%);
}
:where(
  .ref-task-page .daily-send,
  .social-send,
  .chat-layout .send-button
):hover:not(:disabled) {
  transform: translateY(-1.5px) scale(1.03);
  background: linear-gradient(145deg, #0d8a94 0%, #096169 100%) !important;
  border-color: #0b7a83 !important;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 34%),
    0 6px 18px rgb(11 122 131 / 34%);
}
:where(
  .ref-task-page .daily-send,
  .social-send,
  .chat-layout .send-button
):active:not(:disabled) {
  transform: translateY(0) scale(.96);
}

/* 3. Uiverse Galaxy 聚光灯追随表面卡片 (Spotlight Cards) */
:where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item,
  .yb-orch-card,
  .simple-creation-page .simple-task,
  .daily-page .business-task
) {
  position: relative;
  overflow: hidden;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 80%),
    0 1px 3px rgb(13 29 34 / 4%),
    0 8px 24px -8px rgb(13 29 34 / 6%);
  transition:
    transform 220ms var(--yb-ease),
    border-color 220ms var(--yb-ease),
    box-shadow 260ms var(--yb-ease),
    background-color 220ms var(--yb-ease);
}
:where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item,
  .yb-orch-card
)::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 260ms var(--yb-ease);
  background: radial-gradient(
    280px circle at var(--uv-mx, 50%) var(--uv-my, 50%),
    rgb(43 179 177 / 11%),
    transparent 65%
  );
}
:where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item,
  .yb-orch-card
):hover::before {
  opacity: 1;
}
:where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item
):hover {
  border-color: rgb(11 122 131 / 32%);
  box-shadow:
    inset 0 1px 0 #fff,
    0 4px 12px rgb(13 29 34 / 6%),
    0 16px 36px -10px rgb(11 122 131 / 14%);
}

/* 4. Uiverse 悬浮陶瓷输入舱（带动态呼吸柔光焦点环） */
:where(
  .ref-task-page .daily-composer,
  .daily-page .daily-composer,
  .social-composer,
  .chat-layout .composer
) {
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 90%),
    0 2px 6px rgb(13 29 34 / 4%),
    0 12px 32px -8px rgb(13 29 34 / 7%);
  transition:
    border-color 200ms var(--yb-ease),
    box-shadow 240ms var(--yb-ease),
    transform 200ms var(--yb-ease);
}

/* 5. 高触感快捷胶囊与灵感芯片 */
:where(
  .ref-creation-shortcut,
  .yb-inspiration-chip,
  .daily-page .daily-starter,
  .chat-layout .quick-start
) {
  position: relative;
  overflow: hidden;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 85%),
    0 1px 3px rgb(13 29 34 / 4%);
  transition:
    transform 180ms var(--yb-ease),
    border-color 180ms var(--yb-ease),
    box-shadow 220ms var(--yb-ease),
    background-color 180ms var(--yb-ease);
}
:where(
  .ref-creation-shortcut,
  .yb-inspiration-chip,
  .daily-page .daily-starter,
  .chat-layout .quick-start
):hover:not(:disabled) {
  transform: translateY(-1.5px);
  border-color: rgb(11 122 131 / 34%);
  box-shadow:
    inset 0 1px 0 #fff,
    0 6px 18px -4px rgb(11 122 131 / 14%);
}
:where(
  .ref-creation-shortcut,
  .yb-inspiration-chip,
  .daily-page .daily-starter,
  .chat-layout .quick-start
):active:not(:disabled) {
  transform: translateY(0) scale(.98);
}

/* Rail navigation */
.reference-mode .ref-rail .ref-rail-button {
  position: relative;
  transition:
    background-color 160ms var(--yb-ease),
    color 160ms var(--yb-ease),
    transform 140ms var(--yb-ease);
}

/* 7. 暗黑模式 Uiverse Galaxy 聚光灯与输入舱镜面适配 */
html[data-yb-theme='dark'] :where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item,
  .yb-orch-card,
  .simple-creation-page .simple-task,
  .daily-page .business-task
) {
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 6%),
    0 4px 16px rgb(0 0 0 / 28%);
}
html[data-yb-theme='dark'] :where(
  .dlb-card,
  .fc-card,
  .bs-skill-card,
  .conn-card,
  .social-group-ai-card,
  .accounts-page .account-source-option,
  .viral-sample-item,
  .yb-orch-card
)::before {
  background: radial-gradient(
    280px circle at var(--uv-mx, 50%) var(--uv-my, 50%),
    rgb(127 227 214 / 10%),
    transparent 65%
  );
}
html[data-yb-theme='dark'] :where(
  .ref-creation-shortcut,
  .yb-inspiration-chip,
  .daily-page .daily-starter,
  .chat-layout .quick-start
) {
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 7%),
    0 2px 8px rgb(0 0 0 / 26%);
}
html[data-yb-theme='dark'] :where(
  .ref-creation-shortcut,
  .yb-inspiration-chip,
  .daily-page .daily-starter,
  .chat-layout .quick-start
):hover:not(:disabled) {
  border-color: #2bb3b1 !important;
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 12%),
    0 8px 22px -4px rgb(0 0 0 / 45%) !important;
}
