/* ============================================================
   pc.css —— PC 端双栏布局（纯桌面版，不做移动端响应）
   会话列表左侧常驻 + 群组/私聊聊天区右侧切换
   本文件在 dm.css 之后加载，覆盖移动端的 fixed 全屏定位。
   ============================================================ */
body {
  display: flex;
}

/* 左侧：会话列表，固定宽度 */
#view-list {
  width: 320px;
  flex-shrink: 0;
  height: 100%;
  border-right: 1px solid var(--border);
}

/* 右侧：聊天区（群组 / 私聊），占剩余宽度 */
#view-room,
#view-dm {
  flex: 1;
  min-width: 0;
  height: 100%;
  position: relative;
}

/* 聊天页：从 fixed 全屏改为相对定位，撑满右侧 */
#view-room .chat-page,
#view-dm .chat-page {
  position: relative;
  top: auto;
  left: auto;
  right: auto;
  width: 100%;
  height: 100%;
}

/* 双栏布局下，会话列表常驻左侧，聊天页返回按钮不再需要 */
.chat-header .back-btn {
  display: none;
}

/* 聊天头部高度与左侧列表头部 .header 对齐（.header 由 40px 按钮 + 16/12 上下内边距构成，约 68px） */
.chat-header {
  min-height: 68px;
}

/* 右侧空状态（未选中会话时） */
#view-empty {
  flex: 1;
  min-width: 0;
  height: 100%;
}
.pc-empty {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: var(--bg);
  color: var(--text-3);
  user-select: none;
}
.pc-empty-logo {
  width: 92px;
  height: 92px;
  border-radius: 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px -12px rgba(102, 126, 234, .35);
}
.pc-empty-title {
  font-size: .95rem;
  color: var(--text-3);
}

/* 深色主题：列表分隔线 */
[data-theme="dark"] #view-list {
  border-right-color: var(--border);
}

/* ==================== 抽屉 → 居中弹窗 ==================== */
.settings-drawer,
.dm-drawer,
.user-panel,
.mention-drawer {
  position: fixed;
  left: 50%;
  top: 50%;
  right: auto;
  bottom: auto;
  transform: translate(-50%, -50%) scale(.96);
  width: 400px;
  max-width: 92vw;
  height: 70vh;
  max-height: 80vh;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 64px -16px rgba(0, 0, 0, .4);
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
}

.settings-drawer.show,
.dm-drawer.show,
.user-panel.open,
.mention-drawer.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

/* 加号菜单：改为居中弹窗 */
.add-menu {
  top: 50%;
  left: 50%;
  right: auto;
  transform: translate(-50%, -50%) scale(.96);
  transform-origin: center;
}
.add-menu.show {
  transform: translate(-50%, -50%) scale(1);
}

/* 输入栏直接显示的工具按钮（表情 / 相册），与语音切换按钮风格一致 */
.chat-footer .chat-tool-btn {
  font-size: 1.25rem;
  background: none;
  border: none;
  padding: 4px;
  min-width: 34px;
  color: #888;
  cursor: pointer;
  line-height: 1;
  position: relative;
}
.chat-footer .chat-tool-btn:hover {
  color: var(--primary);
}

/* 输入框默认加高到四行，最多可到约八行；圆角改为矩形 */
.chat-footer .msg-input {
  min-height: 100px;
  max-height: 220px;
  border-radius: 12px;
}

/* 输入栏整体间距加宽：按钮与输入框间距、左右留白 */
.chat-footer {
  gap: .85rem;
  padding: .6rem 1.25rem;
}

/* 发送图片前的预览缩略图：与四行输入框高度一致 */
.image-preview-panel .ipp-item,
.image-preview-panel .ipp-add {
  width: 100px;
  height: 100px;
  border-radius: 10px;
}
.image-preview-panel .ipp-remove {
  width: 20px;
  height: 20px;
  font-size: .8rem;
}

/* 录音按钮高度与四行输入框对齐 */
.chat-footer .voice-record-btn {
  height: 100px;
  border-radius: 12px;
}
.chat-footer .voice-cancel-btn {
  height: 100px;
}
