:root {
  --bg: #080b16;
  --bg2: #0d1428;
  --panel: rgba(255, 255, 255, 0.045);
  --panel-2: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.09);
  --text: #e8edf7;
  --muted: #8a97b1;
  --accent: #45c8f5;
  --accent2: #a78bfa;
  --ok: #3ddc97;
  --err: #ff6b81;
  --warn: #ffc861;
  --radius: 18px;
  --side: 244px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  background:
    radial-gradient(900px 520px at 8% -10%, rgba(69, 200, 245, 0.14), transparent 60%),
    radial-gradient(820px 500px at 92% 2%, rgba(167, 139, 250, 0.13), transparent 62%),
    linear-gradient(170deg, var(--bg) 0%, var(--bg2) 55%, #060912 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, "Segoe UI", "Noto Sans SC", "Microsoft YaHei", "PingFang SC", Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
.hidden { display: none !important; }

/* ==================== 登录 ==================== */
.login-wrap {
  min-height: 100vh; display: grid; place-items: center; padding: 24px;
}
.login-card {
  width: 100%; max-width: 372px;
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 22px; padding: 38px 32px 26px;
  backdrop-filter: blur(18px);
  box-shadow: 0 40px 90px -50px #000, inset 0 1px 0 rgba(255,255,255,.06);
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.logo {
  width: 46px; height: 46px; border-radius: 14px;
  background: linear-gradient(140deg, var(--accent), var(--accent2));
  display: grid; place-items: center;
  box-shadow: 0 12px 32px -12px rgba(69, 200, 245, .8);
}
.logo.lg { width: 58px; height: 58px; border-radius: 18px; margin-bottom: 4px; }
.logo.lg svg { width: 32px; height: 32px; }
.logo.sm { width: 38px; height: 38px; border-radius: 12px; flex: none; }
.logo.sm svg { width: 22px; height: 22px; }
.login-card h1 { font-size: 21px; margin: 6px 0 0; font-weight: 650; letter-spacing: .4px; }
.login-card .sub { color: var(--muted); font-size: 13px; margin: 0 0 8px; }
.login-card input {
  width: 100%; margin-top: 6px; text-align: center; letter-spacing: 3px;
  font-size: 16px; padding: 12px 14px;
}
.login-card button { width: 100%; margin-top: 4px; padding: 12px; font-size: 14.5px; }
.login-err { color: var(--err); font-size: 12.5px; height: 17px; }
.login-note { color: var(--muted); font-size: 11.5px; margin: 6px 0 0; text-align: center; }

/* ==================== 布局 ==================== */
.app { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--side); flex: none;
  background: rgba(6, 10, 20, 0.62);
  border-right: 1px solid var(--border);
  backdrop-filter: blur(16px);
  padding: 20px 14px;
  display: flex; flex-direction: column; gap: 22px;
  position: sticky; top: 0; height: 100vh;
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 6px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: 15px; letter-spacing: .3px; }
.brand-text span { font-size: 11.5px; color: var(--muted); }

nav#nav { display: flex; flex-direction: column; gap: 12px; }
.nav-item {
  display: flex; align-items: center; gap: 13px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.055);
  color: var(--muted);
  padding: 16px 17px; border-radius: 15px; cursor: pointer;
  font-size: 15px; font-family: inherit; font-weight: 500;
  transition: .16s; text-align: left; width: 100%;
}
.nav-item svg { width: 22px; height: 22px; flex: none; opacity: .85; }
.nav-item:hover {
  background: rgba(255, 255, 255, 0.075);
  border-color: rgba(255, 255, 255, 0.13);
  color: #cfe0f2;
  transform: translateY(-1px);
}
.nav-item.active {
  background: linear-gradient(135deg, rgba(69,200,245,.18), rgba(167,139,250,.15));
  border-color: rgba(69,200,245,.32);
  color: #bdeaff;
  box-shadow: inset 0 0 0 1px rgba(69,200,245,.18), 0 10px 24px -16px rgba(69,200,245,.9);
}
.nav-item.active svg { opacity: 1; }

.side-foot { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 0 4px; }
.who { display: flex; align-items: center; gap: 9px; font-size: 13px; color: #c6d4e6; min-width: 0; }
.who span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #06121e; font-weight: 700; font-size: 13px;
  display: grid; place-items: center; text-transform: uppercase;
}

.main { flex: 1; min-width: 0; padding: 26px 30px 70px; }
.view { display: none; animation: fade .22s ease; }
.view.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.view-head {
  display: flex; align-items: flex-start; gap: 16px; margin-bottom: 22px; flex-wrap: wrap;
}
.view-head h2 { font-size: 21px; margin: 0 0 3px; font-weight: 650; letter-spacing: .3px; }
.view-head p { margin: 0; color: var(--muted); font-size: 12.5px; }
.view-head .status { margin-left: auto; }

/* ==================== 通用组件 ==================== */
.card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: var(--radius); backdrop-filter: blur(14px);
}
.card.pad { padding: 20px; }

.status {
  display: flex; align-items: center; gap: 8px;
  background: var(--panel); border: 1px solid var(--border);
  padding: 7px 13px; border-radius: 999px; font-size: 12.5px; color: var(--muted);
  white-space: nowrap;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.dot.bad { background: var(--err); box-shadow: 0 0 10px var(--err); }
.dot.warn { background: var(--warn); box-shadow: 0 0 10px var(--warn); }

input, select {
  background: rgba(9, 14, 28, 0.85); color: var(--text);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 9px 12px; font-size: 13.5px; font-family: inherit; outline: none;
  transition: .15s;
}
input:focus, select:focus { border-color: rgba(69, 200, 245, .6); }
input.short { max-width: 130px; }
input.short.wide { max-width: 210px; }
select option { background: #0d1428; }

button {
  font-family: inherit; font-size: 13.5px; cursor: pointer; border: none;
  border-radius: 11px; padding: 10px 20px; font-weight: 600; transition: .16s;
  color: #04121c; background: linear-gradient(135deg, var(--accent), #7dd3fc);
  box-shadow: 0 8px 22px -12px rgba(69, 200, 245, .9);
}
button:hover { transform: translateY(-1px); }
button:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn.ghost {
  background: var(--panel-2); color: var(--text);
  border: 1px solid var(--border); box-shadow: none; font-weight: 500;
}
.btn.ghost:hover { border-color: rgba(255,255,255,.22); }
.btn.tiny { padding: 6px 12px; font-size: 12px; border-radius: 9px; }

.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 16px; }
.spacer { flex: 1; }
.field { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.queue { color: var(--muted); font-size: 13px; }
.pending { color: var(--muted); font-size: 12.5px; margin-top: 10px; word-break: break-all; }
.note { color: var(--muted); font-size: 12px; }

.dropzone {
  border: 1.6px dashed rgba(120, 150, 200, 0.42);
  border-radius: 15px; padding: 34px 24px; text-align: center;
  cursor: pointer; transition: .18s ease; background: rgba(255,255,255,0.012);
}
.dropzone:hover { border-color: rgba(69, 200, 245, 0.65); background: rgba(69, 200, 245, 0.05); }
.dropzone.drag { border-color: var(--accent); background: rgba(69, 200, 245, 0.1); transform: scale(1.006); }
.dropzone .big { font-size: 16px; font-weight: 600; margin: 12px 0 6px; word-break: break-all; }
.dropzone .hint { color: var(--muted); font-size: 12.5px; }
.dropzone svg { width: 40px; height: 40px; opacity: .85; }

/* ==================== 列表 ==================== */
.list-head { display: flex; align-items: center; gap: 10px; margin: 26px 2px 12px; }
.list-head h3 { font-size: 15px; margin: 0; font-weight: 600; letter-spacing: .4px; }
.list-head .count { color: var(--muted); font-size: 12.5px; }

.item {
  padding: 16px 18px; margin-bottom: 12px; display: flex; gap: 15px; align-items: flex-start;
  transition: .2s;
}
.item:hover { border-color: rgba(255,255,255,.16); }
.item .ico {
  width: 34px; height: 34px; flex: none; border-radius: 10px;
  background: rgba(255,255,255,.06); display: grid; place-items: center;
}
.item .ico svg { width: 18px; height: 18px; opacity: .8; }
.item .body { flex: 1; min-width: 0; }
.item .top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.item .name { font-weight: 600; font-size: 14.5px; word-break: break-all; }
.item .meta { color: var(--muted); font-size: 12.5px; margin-top: 3px; }

.badge { font-size: 11.5px; padding: 3px 10px; border-radius: 999px; font-weight: 600; }
.b-queued { background: rgba(255,255,255,.08); color: #b9c4d6; }
.b-running { background: rgba(69,200,245,.14); color: #86dcff; }
.b-done { background: rgba(61,220,151,.14); color: #6ff0b7; }
.b-failed { background: rgba(255,107,129,.14); color: #ff97a6; }
.b-flip { background: rgba(255,200,97,.16); color: #ffd489; }

.bar { height: 5px; background: rgba(255,255,255,.07); border-radius: 99px; overflow: hidden; margin-top: 11px; }
.bar > i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  border-radius: 99px; transition: width .5s ease;
}
.bar.running > i {
  background-image: linear-gradient(90deg, var(--accent), var(--accent2), var(--accent));
  background-size: 220% 100%; animation: flow 1.4s linear infinite;
}
@keyframes flow { to { background-position: 220% 0; } }

.msg { color: var(--muted); font-size: 12px; margin-top: 8px; word-break: break-all; }
.msg b { color: #9db8d8; }

.actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.actions a, .actions button {
  font-size: 12.5px; padding: 7px 14px; border-radius: 9px; text-decoration: none; font-weight: 600;
}
.dl-main { background: linear-gradient(135deg, var(--ok), #7ef0c0); color: #04140d; }
.dl-alt { background: var(--panel-2); color: var(--text); border: 1px solid var(--border); }
.dl-main:hover, .dl-alt:hover { transform: translateY(-1px); }
.btn-flip { background: linear-gradient(135deg, var(--warn), #ffdf9b); color: #241a02; }

.empty { text-align: center; color: var(--muted); padding: 42px 20px; font-size: 13.5px; }

/* ==================== 打印页 ==================== */
.print-opts {
  display: flex; flex-wrap: wrap; gap: 20px; align-items: center;
  margin-top: 18px;
}
.opt-group { display: flex; align-items: center; gap: 10px; }
.opt-label { font-size: 13px; color: var(--muted); }
.segmented {
  display: inline-flex; background: rgba(9,14,28,.8); border: 1px solid var(--border);
  border-radius: 11px; padding: 3px; gap: 3px;
}
.seg {
  background: transparent; color: var(--muted); border: none; box-shadow: none;
  padding: 7px 15px; border-radius: 8px; font-size: 13px; font-weight: 500;
}
.seg:hover { transform: none; color: #cfe0f2; }
.seg.active {
  background: linear-gradient(135deg, rgba(69,200,245,.22), rgba(167,139,250,.18));
  color: #cdefff; box-shadow: inset 0 0 0 1px rgba(69,200,245,.3);
}

.fixed-props { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.chip {
  font-size: 12px; color: #9fb6d2; background: rgba(255,255,255,.05);
  border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px;
}

.duplex-note {
  margin-top: 16px; padding: 16px 18px; border-radius: 14px;
  background: rgba(255, 200, 97, 0.07);
  border: 1px solid rgba(255, 200, 97, 0.28);
  font-size: 13px; color: #e7d5b0;
}
.duplex-note strong { color: #ffd489; display: block; margin-bottom: 8px; font-size: 13.5px; }
.duplex-note ol { margin: 0 0 8px; padding-left: 20px; }
.duplex-note li { margin-bottom: 4px; }
.duplex-note b { color: #ffe4b0; }
.duplex-note .tip { margin: 0; font-size: 12px; color: #b9a887; }
.align-pick { margin-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.align-pick .segmented { align-self: flex-start; }

/* ==================== 设置 / 表格 ==================== */
.settings { margin-top: 24px; overflow: hidden; }
.settings summary {
  cursor: pointer; padding: 15px 20px; font-size: 13.5px; font-weight: 600;
  list-style: none; display: flex; align-items: center; gap: 8px; color: #cdd8e8;
}
.settings summary::-webkit-details-marker { display: none; }
.settings summary small { color: var(--muted); font-weight: 400; }
.settings .inner { padding: 4px 20px 22px; display: grid; gap: 13px; }
.settings .line { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.settings label { font-size: 13px; color: var(--muted); min-width: 106px; }
.settings input { flex: 1; min-width: 200px; }

.stats-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.stats-table th, .stats-table td {
  padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border);
}
.stats-table th { color: var(--muted); font-weight: 600; font-size: 12.5px; letter-spacing: .3px; }
.stats-table tbody tr:hover { background: rgba(255,255,255,.03); }
.stats-table td.num, .stats-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.stats-table tfoot td { font-weight: 700; color: #cfe0f2; border-bottom: none; }
.empty-cell { text-align: center; color: var(--muted); }
.role-tag { font-size: 11.5px; padding: 2px 9px; border-radius: 999px; background: rgba(167,139,250,.16); color: #c9b8ff; }
.role-tag.user { background: rgba(255,255,255,.07); color: #a9b7c9; }

/* ==================== toast ==================== */
.toast {
  position: fixed; left: 50%; bottom: 32px; transform: translateX(-50%) translateY(18px);
  background: #16203a; border: 1px solid var(--border); color: var(--text);
  padding: 11px 20px; border-radius: 12px; font-size: 13.5px; opacity: 0;
  transition: .25s; pointer-events: none; box-shadow: 0 18px 40px -18px #000;
  max-width: 86vw; text-align: center; z-index: 99;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.err { border-color: rgba(255,107,129,.5); }

/* ==================== 响应式 ==================== */
@media (max-width: 860px) {
  .app { flex-direction: column; }
  .sidebar {
    width: 100%; height: auto; position: static; flex-direction: row;
    align-items: center; gap: 12px; padding: 12px 14px; overflow-x: auto;
  }
  .brand-text { display: none; }
  nav#nav { flex-direction: row; gap: 8px; }
  .nav-item { padding: 10px 14px; white-space: nowrap; border-radius: 12px; font-size: 13.5px; }
  .nav-item svg { width: 18px; height: 18px; }
  .nav-item span { display: inline; }
  .side-foot { margin-top: 0; margin-left: auto; }
  .main { padding: 18px 14px 60px; }
  .view-head .status { margin-left: 0; }
  .stats-table { font-size: 12.5px; }
  .stats-table th, .stats-table td { padding: 10px 8px; }
  .settings label { min-width: 100%; }
}

/* ==================== 工作同步 ==================== */
.ws-head-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.ws-head-actions .btn { font-size: 13px; padding: 9px 16px; }

.ws-layout {
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.ws-side {
  padding: 14px; display: flex; flex-direction: column; gap: 10px;
  position: sticky; top: 16px;
  min-height: 440px; height: calc(100vh - 34px); max-height: 1100px;
}
.ws-side-head {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13px; color: var(--muted); font-weight: 600; padding: 2px 4px;
}
.ws-count {
  background: rgba(255,255,255,.08); border-radius: 999px;
  padding: 1px 9px; font-size: 11.5px; color: #c3d2e6;
}
.ws-list { display: flex; flex-direction: column; gap: 6px; flex: 1; min-height: 0; overflow-y: auto; }
.ws-empty { color: var(--muted); font-size: 12.5px; text-align: center; padding: 26px 8px; }
.ws-item {
  padding: 10px 12px; border-radius: 11px; cursor: pointer;
  border: 1px solid transparent; transition: .15s; background: rgba(255,255,255,.025);
}
.ws-item:hover { background: rgba(255,255,255,.07); }
.ws-item.active {
  background: linear-gradient(135deg, rgba(69,200,245,.16), rgba(167,139,250,.13));
  border-color: rgba(69,200,245,.3);
}
.ws-item .t { font-size: 13.5px; font-weight: 600; word-break: break-all; line-height: 1.35; }
.ws-item .m { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.ws-side-foot {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  border-top: 1px solid var(--border); padding-top: 10px; margin-top: auto;
}
.ws-cfg { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.ws-cfg input { max-width: 62px; padding: 5px 8px; font-size: 12px; }

.ws-main { padding: 0; overflow: hidden; display: flex; flex-direction: column; min-height: 520px; }
.ws-editor-head {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  border-bottom: 1px solid var(--border); flex-wrap: wrap;
}
.ws-title {
  flex: 1; min-width: 160px; background: transparent; border: none;
  font-size: 16px; font-weight: 650; color: var(--text); padding: 4px 2px;
}
.ws-title:focus { outline: none; border-bottom: 1px solid rgba(69,200,245,.5); }
.ws-title:disabled { color: var(--muted); }
.ws-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ws-tools .segmented { padding: 2px; }
.ws-tools .seg { padding: 5px 11px; font-size: 12.5px; }

.ws-toolbar {
  display: flex; align-items: center; gap: 4px; padding: 8px 16px;
  border-bottom: 1px solid var(--border); background: rgba(255,255,255,.018);
  flex-wrap: wrap;
}
.ws-toolbar button, .ws-tool-file {
  background: transparent; border: none; color: var(--muted); box-shadow: none;
  width: 30px; height: 30px; border-radius: 8px; font-size: 13.5px;
  display: grid; place-items: center; cursor: pointer; transition: .14s;
  font-family: inherit;
}
.ws-toolbar button:hover, .ws-tool-file:hover { background: rgba(255,255,255,.09); color: var(--text); transform: none; }
.ws-tool-spacer { flex: 1; }
.ws-save-state { font-size: 12px; color: var(--muted); }

.ws-panes { flex: 1; display: grid; grid-template-columns: 1fr 1fr; min-height: 380px; }
/* 单栏模式下改成 1fr：否则 display:none 掉一个面板后，
   另一个面板会落到宽度为 0 的第一列，内容被压成一条 */
.ws-panes.mode-edit { grid-template-columns: 1fr; }
.ws-panes.mode-edit .ws-preview { display: none; }
.ws-panes.mode-edit .ws-editor { border-right: none; }
.ws-panes.mode-preview { grid-template-columns: 1fr; }
.ws-panes.mode-preview .ws-editor { display: none; }
.ws-panes.mode-preview .ws-preview { max-height: none; }

.ws-editor {
  border: none; border-right: 1px solid var(--border); background: transparent;
  color: var(--text); padding: 16px 18px; font-size: 13.5px; line-height: 1.75;
  font-family: "JetBrains Mono", Consolas, "Cascadia Code", monospace;
  resize: none; outline: none; min-height: 380px; width: 100%;
}
.ws-editor:disabled { color: var(--muted); }
.ws-preview {
  padding: 16px 20px; overflow-y: auto; max-height: 62vh;
  font-size: 14px; line-height: 1.78;
}

/* markdown 渲染样式 */
.md-body h1, .md-body h2, .md-body h3 { margin: 1.1em 0 .5em; line-height: 1.35; font-weight: 650; }
.md-body h1 { font-size: 1.55em; }
.md-body h2 { font-size: 1.28em; }
.md-body h3 { font-size: 1.1em; }
.md-body p { margin: .7em 0; }
.md-body ul, .md-body ol { margin: .6em 0; padding-left: 1.4em; }
.md-body li { margin: .25em 0; }
.md-body blockquote {
  margin: .8em 0; padding: .5em 1em; border-left: 3px solid rgba(69,200,245,.5);
  background: rgba(69,200,245,.06); color: #cfe0f2; border-radius: 0 8px 8px 0;
}
.md-body code {
  background: rgba(255,255,255,.09); padding: .12em .4em; border-radius: 5px;
  font-family: Consolas, monospace; font-size: .9em;
}
.md-body pre {
  background: rgba(0,0,0,.35); padding: 12px 14px; border-radius: 10px;
  overflow-x: auto; border: 1px solid var(--border);
}
.md-body pre code { background: none; padding: 0; }
.md-body img { max-width: 100%; border-radius: 10px; margin: .5em 0; }
.md-body a { color: var(--accent); }
.md-body table { border-collapse: collapse; width: 100%; margin: .8em 0; font-size: .95em; }
.md-body th, .md-body td { border: 1px solid var(--border); padding: 7px 10px; text-align: left; }
.md-body th { background: rgba(255,255,255,.05); }
.md-body hr { border: none; border-top: 1px solid var(--border); margin: 1.4em 0; }

.ws-status {
  display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 9px 16px; border-top: 1px solid var(--border);
  font-size: 11.5px; color: var(--muted); background: rgba(255,255,255,.015);
}

.ws-drawer {
  margin-top: 16px; padding: 16px 18px;
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius);
  backdrop-filter: blur(14px);
}
.ws-drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.ws-versions { display: flex; flex-direction: column; gap: 8px; max-height: 300px; overflow-y: auto; }
.ws-ver {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 10px 13px; border-radius: 11px; background: rgba(255,255,255,.03);
  border: 1px solid transparent;
}
.ws-ver.current { border-color: rgba(61,220,151,.35); background: rgba(61,220,151,.07); }
.ws-ver .v { font-weight: 700; font-size: 13px; color: #bdeaff; min-width: 34px; }
.ws-ver .who { font-size: 13px; }
.ws-ver .when { font-size: 11.5px; color: var(--muted); }
.ws-ver .nt { font-size: 12px; color: var(--muted); flex: 1; min-width: 100px; }
.ws-ver button { font-size: 12px; padding: 5px 11px; border-radius: 8px; }

@media (max-width: 980px) {
  .ws-layout { grid-template-columns: 1fr; }
  .ws-side { position: static; height: auto; min-height: 0; max-height: none; }
  .ws-list { max-height: 210px; flex-direction: row; overflow-x: auto; }
  .ws-item { min-width: 180px; }
  .ws-panes { grid-template-columns: 1fr; }
  .ws-panes.mode-split .ws-preview { display: none; }
  .ws-editor { border-right: none; border-bottom: 1px solid var(--border); }
}

/* ---- 工作同步：文件夹 ---- */
.ws-side-actions { display: flex; align-items: center; gap: 6px; }
.ws-icon-btn {
  background: rgba(255,255,255,.06); border: 1px solid var(--border);
  color: var(--muted); width: 24px; height: 24px; border-radius: 8px;
  font-size: 14px; line-height: 1; cursor: pointer;
  display: grid; place-items: center; box-shadow: none; padding: 0; transition: .15s;
}
.ws-icon-btn:hover {
  background: rgba(69,200,245,.16); color: var(--accent);
  border-color: rgba(69,200,245,.42); transform: none;
}

.ws-folder { margin-bottom: 3px; }
.ws-folder-head {
  display: flex; align-items: center; gap: 7px; padding: 8px 10px;
  border-radius: 10px; cursor: pointer; user-select: none;
  font-size: 13px; color: #c3d2e6; transition: .15s;
}
.ws-folder-head:hover { background: rgba(255,255,255,.06); }
.ws-folder-arrow { font-size: 10px; color: var(--muted); width: 10px; text-align: center; }
.ws-folder-name { font-weight: 600; flex: 1; word-break: break-all; }
.ws-folder-count {
  font-size: 11px; color: var(--muted); background: rgba(255,255,255,.07);
  border-radius: 999px; padding: 1px 8px; flex: none;
}
.ws-folder-body { padding-left: 12px; display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }
.ws-folder.collapsed .ws-folder-body { display: none; }
.ws-folder-empty { font-size: 12px; color: var(--muted); padding: 8px 12px; }
.ws-group-label {
  font-size: 11.5px; color: var(--muted); padding: 10px 6px 6px;
  letter-spacing: .5px;
}

.ws-folder-sel {
  max-width: 132px; padding: 5px 8px; font-size: 12.5px;
  background: rgba(9,14,28,.85); color: var(--text);
  border: 1px solid var(--border); border-radius: 9px; outline: none;
}
.ws-folder-sel:focus { border-color: rgba(69,200,245,.6); }
.ws-folder-sel:disabled { opacity: .45; }

/* ---- 工作同步：文件夹上的操作按钮 ---- */
.ws-folder-actions { display: flex; gap: 3px; flex: none; opacity: 0; transition: .15s; }
.ws-folder-head:hover .ws-folder-actions { opacity: 1; }
.ws-mini-btn {
  width: 20px; height: 20px; border-radius: 6px; padding: 0;
  background: rgba(255,255,255,.08); border: 1px solid var(--border);
  color: var(--muted); font-size: 11px; line-height: 1;
  display: grid; place-items: center; cursor: pointer; box-shadow: none;
  font-family: inherit; transition: .14s;
}
.ws-mini-btn:hover {
  background: rgba(69,200,245,.2); color: var(--accent);
  border-color: rgba(69,200,245,.45); transform: none;
}
.ws-mini-btn.danger:hover {
  background: rgba(255,107,129,.2); color: var(--err);
  border-color: rgba(255,107,129,.45);
}
@media (hover: none) { .ws-folder-actions { opacity: 1; } }

/* ==================== 上传文档弹窗 ==================== */
.ws-modal { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: 20px; }
.ws-modal.hidden { display: none; }
.ws-modal-mask { position: absolute; inset: 0; background: rgba(3, 7, 14, 0.72); backdrop-filter: blur(5px); }
.ws-modal-card {
  position: relative; width: min(560px, 100%);
  background: #0d1428; border: 1px solid var(--border); border-radius: 20px;
  box-shadow: 0 40px 90px -40px #000;
  display: flex; flex-direction: column; max-height: calc(100vh - 40px);
  animation: wsPop .18s ease;
}
@keyframes wsPop {
  from { opacity: 0; transform: translateY(10px) scale(.985); }
  to { opacity: 1; transform: none; }
}
.ws-modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.ws-modal-head strong { font-size: 15px; }
.ws-modal-x {
  background: transparent; border: none; box-shadow: none; color: var(--muted);
  font-size: 15px; cursor: pointer; width: 28px; height: 28px; border-radius: 8px;
  display: grid; place-items: center; padding: 0; transition: .15s;
}
.ws-modal-x:hover { background: rgba(255,255,255,.08); color: var(--text); transform: none; }
.ws-modal-body { padding: 18px 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; }
.ws-upload-drop { padding: 32px 20px; }
.ws-upload-list { display: flex; flex-direction: column; gap: 6px; max-height: 168px; overflow-y: auto; }
.ws-upload-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  background: rgba(255,255,255,.04); border: 1px solid var(--border);
  border-radius: 10px; font-size: 13px;
}
.ws-upload-item .nm { flex: 1; word-break: break-all; }
.ws-upload-item .sz { color: var(--muted); font-size: 12px; flex: none; }
.ws-upload-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ws-modal-foot {
  display: flex; justify-content: flex-end; gap: 10px;
  padding: 14px 20px; border-top: 1px solid var(--border);
}

/* ---- 工作同步：搜索框 ---- */
.ws-search-wrap { position: relative; }
.ws-search {
  width: 100%; padding: 8px 30px 8px 11px; font-size: 12.5px;
  background: rgba(9, 14, 28, .85); border: 1px solid var(--border);
  border-radius: 10px; color: var(--text); outline: none; transition: .15s;
  font-family: inherit;
}
.ws-search:focus { border-color: rgba(69, 200, 245, .55); }
.ws-search::-webkit-search-cancel-button { display: none; }
.ws-search::placeholder { color: #6a7994; }
.ws-search-clear {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 20px; height: 20px; border-radius: 6px; padding: 0;
  background: transparent; border: none; box-shadow: none;
  color: var(--muted); font-size: 11px; cursor: pointer;
  display: grid; place-items: center; transition: .14s;
}
.ws-search-clear:hover {
  background: rgba(255,255,255,.1); color: var(--text); transform: translateY(-50%);
}
.ws-item .sm {
  font-size: 11.5px; color: #8fa6c0; margin-top: 3px; line-height: 1.45;
  max-height: 2.9em; overflow: hidden; word-break: break-all;
}

/* ---- 工作同步：文档项重命名按钮 ---- */
.ws-item { position: relative; }
.ws-item .t { padding-right: 24px; }
.ws-item-rename {
  position: absolute; right: 6px; top: 8px;
  width: 20px; height: 20px; border-radius: 6px; padding: 0;
  background: rgba(255,255,255,.08); border: 1px solid var(--border);
  color: var(--muted); font-size: 11px; line-height: 1; cursor: pointer;
  display: none; place-items: center; box-shadow: none; transition: .14s;
  font-family: inherit;
}
.ws-item:hover .ws-item-rename { display: grid; }
.ws-item-rename:hover {
  background: rgba(69,200,245,.2); color: var(--accent);
  border-color: rgba(69,200,245,.45); transform: none;
}
@media (hover: none) { .ws-item-rename { display: grid; } }

/* ---- 工作同步：同步滚动开关 ---- */
.ws-sync-toggle {
  background: rgba(255,255,255,.06); border: 1px solid var(--border);
  color: var(--muted); padding: 5px 11px; border-radius: 9px;
  font-size: 12px; font-weight: 500; cursor: pointer; box-shadow: none;
  font-family: inherit; transition: .15s; white-space: nowrap;
}
.ws-sync-toggle:hover {
  background: rgba(255,255,255,.1); color: #cfe0f2; transform: none;
}
.ws-sync-toggle.on {
  background: rgba(69,200,245,.18); color: #bdeaff;
  border-color: rgba(69,200,245,.42);
}
.ws-sync-toggle.on:hover { background: rgba(69,200,245,.26); }

/* ==================== 服务器状态卡片 ==================== */
.sys-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.sys-card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 14px; padding: 14px 16px; backdrop-filter: blur(12px);
  transition: border-color .2s;
}
.sys-card:hover { border-color: rgba(255,255,255,.16); }
.sc-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; font-size: 12.5px; color: var(--muted);
}
.sc-val {
  font-size: 19px; font-weight: 700; color: var(--text);
  font-variant-numeric: tabular-nums; line-height: 1.1;
}
.sc-bar {
  height: 5px; background: rgba(255,255,255,.08); border-radius: 99px;
  overflow: hidden; margin: 11px 0 9px;
}
.sc-bar > i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  border-radius: 99px; transition: width .45s ease;
}
.sc-bar.warn > i { background: linear-gradient(90deg, var(--warn), #ffdf9b); }
.sc-bar.danger > i { background: linear-gradient(90deg, var(--err), #ff9aa8); }
.sc-foot { font-size: 11.5px; color: var(--muted); line-height: 1.4; word-break: break-all; }

@media (max-width: 620px) {
  .sys-grid { grid-template-columns: repeat(2, 1fr); }
  .sc-val { font-size: 17px; }
}

/* ==================== PDF 预览弹窗 ==================== */
.pdf-modal { position: fixed; inset: 0; z-index: 130; display: grid; place-items: center; padding: 16px; }
.pdf-modal.hidden { display: none; }
.pdf-mask { position: absolute; inset: 0; background: rgba(3, 7, 14, 0.82); backdrop-filter: blur(5px); }
.pdf-box {
  position: relative; width: min(1100px, 96vw); height: 92vh;
  background: #0d1428; border: 1px solid var(--border); border-radius: 16px;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 40px 90px -40px #000;
  animation: wsPop .18s ease;
}
.pdf-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--border);
}
.pdf-head strong { font-size: 14px; word-break: break-all; }
.pdf-head-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.pdf-body { flex: 1; min-height: 0; background: #202020; }
.pdf-body iframe { width: 100%; height: 100%; border: none; display: block; }
@media (max-width: 620px) {
  .pdf-modal { padding: 0; }
  .pdf-box { width: 100vw; height: 100vh; border-radius: 0; border: none; }
}

/* ==================== Clash 面板 ==================== */
.clash-panel { margin-top: 18px; }
.clash-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 14px;
}
.clash-title { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.clash-title strong { font-size: 15px; }
.clash-meta { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.clash-sep { opacity: .5; }
.clash-actions { display: flex; gap: 8px; }

.clash-groups { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.clash-group {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,.05); border: 1px solid var(--border);
  color: var(--muted); padding: 5px 12px; border-radius: 9px;
  font-size: 12.5px; cursor: pointer; box-shadow: none;
  font-family: inherit; transition: .14s; white-space: nowrap;
}
.clash-group:hover { background: rgba(255,255,255,.1); color: #cfe0f2; transform: none; }
.clash-group.active {
  background: rgba(69,200,245,.18); color: #bdeaff;
  border-color: rgba(69,200,245,.42);
}
.cg-count {
  font-size: 10.5px; background: rgba(255,255,255,.1);
  border-radius: 999px; padding: 0 6px; line-height: 1.6;
}

.clash-nodes {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 8px; max-height: 360px; overflow-y: auto;
}
.clash-node {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,.03);
  border: 1px solid transparent; cursor: pointer; font-size: 13px; transition: .14s;
}
.clash-node:hover { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.1); }
.clash-node.current {
  border-color: rgba(61,220,151,.45); background: rgba(61,220,151,.08);
}
.cn-name { flex: 1; word-break: break-all; line-height: 1.35; }
.cn-delay {
  font-size: 11.5px; font-variant-numeric: tabular-nums; flex: none;
  padding: 2px 9px; border-radius: 999px; min-width: 54px; text-align: center;
}
.cn-delay.na { background: rgba(255,255,255,.08); color: var(--muted); }
.cn-delay.fast { background: rgba(61,220,151,.16); color: #6ff0b7; }
.cn-delay.mid { background: rgba(255,200,97,.16); color: #ffd489; }
.cn-delay.slow { background: rgba(255,107,129,.16); color: #ff97a6; }

@media (max-width: 620px) {
  .clash-nodes { grid-template-columns: 1fr; max-height: 300px; }
}

/* ==================== DeepSeek 余额 ==================== */
.ds-balance {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 13px; border-radius: 10px;
  background: rgba(69, 200, 245, .07);
  border: 1px solid rgba(69, 200, 245, .18);
  font-size: 12px; color: var(--muted);
  white-space: nowrap; cursor: default;
  transition: border-color .18s, background .18s;
}
.dsb-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #45c8f5; flex: none;
  box-shadow: 0 0 6px rgba(69, 200, 245, .7);
}
.dsb-label { opacity: .72; font-size: 11.5px; letter-spacing: .2px; }
.dsb-value {
  font-weight: 600; font-variant-numeric: tabular-nums;
  color: #7fd8ff; font-size: 13px;
}
.ds-balance.low {
  border-color: rgba(255, 180, 84, .35);
  background: rgba(255, 180, 84, .08);
}
.ds-balance.low .dsb-value { color: #ffb454; }
.ds-balance.low .dsb-dot { background: #ffb454; box-shadow: 0 0 6px rgba(255, 180, 84, .7); }
.ds-balance.danger {
  border-color: rgba(255, 107, 129, .38);
  background: rgba(255, 107, 129, .09);
}
.ds-balance.danger .dsb-value { color: #ff6b81; }
.ds-balance.danger .dsb-dot { background: #ff6b81; box-shadow: 0 0 6px rgba(255, 107, 129, .7); }
.ds-balance.error { opacity: .65; }
.ds-balance.error .dsb-value { color: var(--muted); font-size: 12px; }
.ds-balance.error .dsb-dot { background: #7a8798; box-shadow: none; }

@media (max-width: 720px) {
  .ds-balance { padding: 6px 10px; }
  .dsb-label { display: none; }
}

/* ==================== 工作同步：加密（仅管理员可见） ==================== */
.ws-lock {
  font-size: 10.5px; margin-right: 4px; opacity: .85;
  filter: grayscale(.15);
}
.ws-item.ws-secret {
  background: rgba(255, 180, 84, .045);
  border-left: 2px solid rgba(255, 180, 84, .55);
  padding-left: 9px;
}
.ws-item.ws-secret .t { color: #ffd489; }
.ws-folder.ws-secret > .ws-folder-head .ws-folder-name {
  color: #ffd489;
}
.ws-folder.ws-secret > .ws-folder-head {
  border-left: 2px solid rgba(255, 180, 84, .5);
  padding-left: 8px;
}

/* 文档项第二个按钮（加密）放在重命名左边 */
.ws-item-secret { right: 30px; }
.ws-item .t { padding-right: 50px; }

/* ==================== 收支统计 ==================== */
.fin-head-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fin-date {
  background: rgba(255,255,255,.05); border: 1px solid var(--border);
  color: var(--text); padding: 6px 10px; border-radius: 8px;
  font-size: 12.5px; font-family: inherit;
}
.fin-dash { color: var(--muted); font-size: 12px; }

.fin-cards {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px; margin-bottom: 16px;
}
.fin-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 14px; padding: 16px 18px; position: relative; overflow: hidden;
}
.fin-card::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
}
.fin-card.in::before     { background: #3ddc97; }
.fin-card.out::before    { background: #ff6b81; }
.fin-card.reimb::before  { background: #ffb454; }
.fin-card.bal::before    { background: #45c8f5; }
.fin-card.neg::before    { background: #ff6b81; }
.fc-label { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.fc-value { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .3px; }
.fin-card.in    .fc-value { color: #6ff0b7; }
.fin-card.out   .fc-value { color: #ff97a6; }
.fin-card.reimb .fc-value { color: #ffd489; }
.fin-card.bal   .fc-value { color: #7fd8ff; }
.fin-card.neg   .fc-value { color: #ff97a6; }
.fc-sub { font-size: 11px; color: var(--muted); margin-top: 6px; opacity: .8; }

.fin-form { margin-bottom: 18px; }
.fin-form-row { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; }
.fin-f { min-width: 120px; }
.fin-f.wide { flex: 1; min-width: 200px; }
.fin-reimb {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 12px; border-radius: 9px; cursor: pointer;
  background: rgba(255,180,84,.08); border: 1px solid rgba(255,180,84,.28);
  font-size: 12.5px; color: #ffd489; user-select: none; white-space: nowrap;
}
.fin-reimb input { accent-color: #ffb454; margin: 0; }
.fin-reimb.disabled { opacity: .35; pointer-events: none; }
.fin-add { padding: 10px 20px; white-space: nowrap; }
.fin-form-hint { font-size: 12px; color: #ff97a6; margin-top: 8px; min-height: 14px; }

.fin-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.fin-item-main { flex: 1; min-width: 0; }
.fin-item-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.fin-item-purpose { font-size: 14px; color: var(--text); }
.fin-item-amount { margin-left: auto; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.fin-item-amount.in  { color: #6ff0b7; }
.fin-item-amount.out { color: #ff97a6; }
.fin-item-sub { font-size: 11.5px; color: var(--muted); margin-top: 5px; }
.fin-tag {
  font-size: 11px; padding: 2px 8px; border-radius: 999px; white-space: nowrap;
}
.fin-tag.in    { background: rgba(61,220,151,.14); color: #6ff0b7; }
.fin-tag.out   { background: rgba(255,107,129,.14); color: #ff97a6; }
.fin-tag.reimb { background: rgba(255,180,84,.14); color: #ffd489; }
.fin-item.is-in { border-left: 2px solid rgba(61,220,151,.4); }
.fin-del { opacity: 0; transition: .15s; }
.fin-item:hover .fin-del { opacity: 1; }

@media (max-width: 720px) {
  .fin-form-row { flex-direction: column; align-items: stretch; }
  .fin-f, .fin-f.wide { min-width: 0; width: 100%; }
  .fin-cards { grid-template-columns: 1fr 1fr; }
  .fin-del { opacity: 1; }
}

/* ==================== 登录记录 ==================== */
.login-log-panel { margin-top: 18px; }
.log-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 14px;
}
.log-title { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.log-title strong { font-size: 15px; }
.log-meta { font-size: 12px; color: var(--muted); }
.log-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.log-sel {
  background: rgba(255,255,255,.05); border: 1px solid var(--border);
  color: var(--text); padding: 6px 10px; border-radius: 8px;
  font-size: 12.5px; font-family: inherit; cursor: pointer;
}
.log-list { max-height: 420px; overflow-y: auto; }
.log-table {
  width: 100%; border-collapse: collapse; font-size: 13px;
}
.log-table th {
  text-align: left; font-weight: 500; font-size: 12px; color: var(--muted);
  padding: 8px 10px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: var(--card); z-index: 1;
}
.log-table td {
  padding: 9px 10px; border-bottom: 1px solid rgba(255,255,255,.04);
  vertical-align: middle;
}
.log-table tr:last-child td { border-bottom: none; }
.log-table tbody tr:hover { background: rgba(255,255,255,.03); }
.log-t { font-variant-numeric: tabular-nums; color: #cfe0f2; }
.log-ip { font-family: ui-monospace, Consolas, monospace; font-size: 12px; color: var(--muted); }
.log-tag {
  font-size: 11px; padding: 2px 8px; border-radius: 999px; white-space: nowrap;
}
.log-tag.pub { background: rgba(69,200,245,.15); color: #7fd8ff; }
.log-tag.int { background: rgba(255,255,255,.08); color: var(--muted); }

@media (max-width: 620px) {
  .log-head { flex-direction: column; align-items: stretch; }
  .log-list { max-height: 300px; }
  .log-table th:nth-child(3), .log-table td:nth-child(3) { display: none; }
}

/* ==================== 工作同步：文件夹/文件视觉区分 ==================== */

/* ---- 文件项：低调的灰白 ---- */
.ws-item .t {
  display: flex;
  align-items: baseline;
  gap: 5px;
}
.ws-item-icon {
  font-size: 11.5px;
  opacity: .38;
  flex: none;
  line-height: 1;
  transform: translateY(-1px);
}
.ws-item:hover .ws-item-icon { opacity: .62; }
.ws-item.active .ws-item-icon { opacity: .8; }

/* ---- 文件夹：青色，明显区别于文件 ---- */
.ws-folder-icon {
  font-size: 12.5px;
  margin-right: 5px;
  line-height: 1;
  filter: saturate(1.1);
}
.ws-folder-head {
  color: #7fd8ff;                                  /* 青色名称 */
  background: rgba(69, 200, 245, .055);            /* 淡青底 */
  border-left: 2px solid rgba(69, 200, 245, .32);
  padding-left: 8px;
}
.ws-folder-head:hover {
  background: rgba(69, 200, 245, .12);
  border-left-color: rgba(69, 200, 245, .55);
}
.ws-folder-name {
  display: flex;
  align-items: baseline;
  gap: 2px;
}
.ws-folder-count {
  color: #9fe3ff;
  background: rgba(69, 200, 245, .14);
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}
.ws-folder-arrow {
  color: rgba(69, 200, 245, .65);
  font-size: 9px;
}

/* 文件夹内容区：明确的缩进 + 层级竖线 */
.ws-folder-body {
  padding-left: 14px;
  margin-left: 7px;
  border-left: 1px solid rgba(69, 200, 245, .16);
  margin-top: 5px;
}
.ws-folder-empty {
  color: rgba(127, 216, 255, .45);
  font-style: italic;
}

/* ---- 加密文件夹：换成琥珀色，与普通文件夹区分 ---- */
.ws-folder.ws-secret > .ws-folder-head {
  color: #ffd489;
  background: rgba(255, 180, 84, .07);
  border-left-color: rgba(255, 180, 84, .45);
}
.ws-folder.ws-secret > .ws-folder-head:hover {
  background: rgba(255, 180, 84, .13);
}
.ws-folder.ws-secret .ws-folder-count {
  color: #ffd489;
  background: rgba(255, 180, 84, .15);
}
.ws-folder.ws-secret .ws-folder-arrow { color: rgba(255, 180, 84, .65); }
.ws-folder.ws-secret > .ws-folder-body { border-left-color: rgba(255, 180, 84, .18); }

/* 未分类标签：稍微加强存在感 */
.ws-group-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  letter-spacing: .3px;
}
.ws-group-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border), transparent);
}

/* ---- 长名称处理：文件夹单行省略，文件最多两行 ---- */
.ws-folder-name {
  display: flex;
  align-items: center;
  gap: 5px;
  flex: 1;
  min-width: 0;                    /* 允许收缩，否则 ellipsis 不生效 */
}
.ws-folder-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
  font-weight: 600;
}
.ws-item .t {
  align-items: flex-start;
}
.ws-item-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-width: 0;
  word-break: break-all;
  line-height: 1.35;
}

/* ---- 文件夹配色再强化（青色系）---- */
.ws-folder-head {
  background: rgba(69, 200, 245, .07);
  box-shadow: inset 0 0 0 1px rgba(69, 200, 245, .10);
}
.ws-folder-head:hover {
  background: rgba(69, 200, 245, .13);
  box-shadow: inset 0 0 0 1px rgba(69, 200, 245, .22);
}
.ws-folder-head .ws-folder-name,
.ws-folder-head .ws-folder-text {
  color: #8fdcff;
}
.ws-folder.ws-secret > .ws-folder-head .ws-folder-text { color: #ffd489; }

/* 文件项：更清淡，衬托文件夹 */
.ws-item {
  background: transparent;
  border: 1px solid transparent;
}
.ws-item:hover { background: rgba(255,255,255,.05); }
.ws-item .t { color: #d5e0ee; font-weight: 500; }
.ws-item.active .t { color: #ffffff; }

/* ---- 文件夹配色：更饱和的青蓝，与灰白文件拉开差距 ---- */
.ws-folder-head {
  background: rgba(79, 195, 247, .10);
  box-shadow: inset 0 0 0 1px rgba(79, 195, 247, .16);
}
.ws-folder-head:hover {
  background: rgba(79, 195, 247, .18);
  box-shadow: inset 0 0 0 1px rgba(79, 195, 247, .30);
}
.ws-folder-head .ws-folder-text {
  color: #4fc3f7;                 /* 饱和青蓝 */
  font-weight: 700;
  letter-spacing: .2px;
}
.ws-folder-head .ws-folder-arrow { color: #4fc3f7; opacity: .8; }
.ws-folder-head .ws-folder-count {
  color: #7dd8ff;
  background: rgba(79, 195, 247, .22);
  border: 1px solid rgba(79, 195, 247, .25);
}
.ws-folder-body {
  border-left: 1px solid rgba(79, 195, 247, .22);
}

/* 加密文件夹保持琥珀色，与普通文件夹明显不同 */
.ws-folder.ws-secret > .ws-folder-head {
  background: rgba(255, 180, 84, .10);
  box-shadow: inset 0 0 0 1px rgba(255, 180, 84, .18);
}
.ws-folder.ws-secret > .ws-folder-head .ws-folder-text { color: #ffb454; }
.ws-folder.ws-secret .ws-folder-count {
  color: #ffc972;
  background: rgba(255, 180, 84, .22);
  border-color: rgba(255, 180, 84, .28);
}
.ws-folder.ws-secret .ws-folder-arrow { color: #ffb454; }
.ws-folder.ws-secret > .ws-folder-body {
  border-left-color: rgba(255, 180, 84, .22);
}
