/* ============ 御邦工作平台 · 设计系统 ============ */
:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-2: #fafbfd;
  --ink: #0f1f33;
  --ink-2: #46536b;
  --ink-3: #8a97a9;
  --line: #e7ebf1;
  --line-2: #f0f3f7;
  --brand: #1b4b7a;
  --brand-2: #2f7dd1;
  --brand-soft: #eaf2fb;
  --danger: #d92d20;
  --danger-soft: #fef3f2;
  --ok: #0e9b6e;
  --ok-soft: #ecfdf5;
  --warn: #b54708;
  --warn-soft: #fffaeb;
  --gold: #b98a3e;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 2px rgba(15, 31, 51, .05), 0 1px 3px rgba(15, 31, 51, .04);
  --shadow-md: 0 2px 6px rgba(15, 31, 51, .06), 0 12px 28px -14px rgba(15, 31, 51, .18);
  --shadow-lg: 0 24px 64px -16px rgba(15, 31, 51, .28);
  --sidebar-w: 240px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro SC", "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", sans-serif;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
input, select, textarea { font: inherit; color: inherit; }
::selection { background: #cfe3fa; }

.ico { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }

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

.sidebar {
  width: var(--sidebar-w);
  flex: none;
  background: var(--surface);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  padding: 18px 14px 14px;
  gap: 14px;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 2px 6px 6px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 9px; overflow: hidden; flex: none;
  display: grid; place-items: center;
}
.brand-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: 14px; letter-spacing: .2px; }
.brand-text span { font-size: 11px; color: var(--ink-3); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 36px; padding: 0 14px;
  border-radius: 9px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink-2);
  font-size: 13px; font-weight: 500; cursor: pointer;
  transition: .16s ease; white-space: nowrap;
}
.btn:hover { border-color: #cfd8e4; background: var(--surface-2); color: var(--ink); }
.btn:active { transform: translateY(.5px); }
.btn-primary { background: linear-gradient(180deg, #215a90, #1b4b7a); border-color: #17456f; color: #fff; box-shadow: 0 2px 6px -1px rgba(27, 75, 122, .35); }
.btn-primary:hover { background: linear-gradient(180deg, #2567a3, #1e5487); border-color: #1c4f7d; color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--line-2); }
.btn-danger { color: var(--danger); border-color: #f3c9c4; background: #fff; }
.btn-danger:hover { background: var(--danger-soft); border-color: #eeb0a8; }
.btn-sm { height: 30px; padding: 0 10px; font-size: 12.5px; border-radius: 8px; }
.btn-block { width: 100%; }

.nav { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; flex: 1; margin: 0 -4px; padding: 0 4px; }
.nav-group { font-size: 10.5px; letter-spacing: .1em; color: #a3aec0; font-weight: 600; padding: 12px 10px 5px; text-transform: uppercase; }
.nav-item {
  display: flex; align-items: center; gap: 9px;
  height: 36px; padding: 0 10px; border-radius: 9px;
  color: var(--ink-2); font-weight: 500; font-size: 13px;
  transition: .15s; position: relative;
}
.nav-item .ico { color: #93a1b5; transition: .15s; }
.nav-item:hover { background: var(--line-2); color: var(--ink); }
.nav-item:hover .ico { color: var(--ink-2); }
.nav-item.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.nav-item.active .ico { color: var(--brand-2); stroke-width: 1.9; }
.nav-item.active::before {
  content: ""; position: absolute; left: -4px; top: 9px; bottom: 9px; width: 3px;
  border-radius: 3px; background: var(--brand-2);
}
.nav-badge {
  margin-left: auto; font-style: normal; font-size: 11px; font-weight: 600;
  min-width: 19px; height: 19px; padding: 0 5px; border-radius: 9px;
  background: var(--line-2); color: var(--ink-3);
  display: grid; place-items: center;
}
.nav-badge:empty { display: none; }
.nav-badge.hot { background: var(--brand-soft); color: var(--brand-2); }
.nav-badge.danger { background: var(--danger-soft); color: var(--danger); }

.sidebar-foot { border-top: 1px solid var(--line-2); padding-top: 12px; }
.sidebar-foot p { font-size: 11px; color: #a3aec0; line-height: 1.5; padding: 6px 4px 0; }
.mini-stat { display: flex; gap: 12px; padding: 0 4px; font-size: 11.5px; color: var(--ink-3); }
.mini-stat b { color: var(--ink); font-size: 13px; font-weight: 600; }

.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 68px; flex: none;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 26px; gap: 20px;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
  position: relative; z-index: 30;
}
.topbar-left h1 { font-size: 18px; font-weight: 600; letter-spacing: -.2px; }
.page-sub { font-size: 12px; color: var(--ink-3); margin-top: 1px; }
.topbar-right { display: flex; align-items: center; gap: 8px; }

.searchbox { position: relative; }
.searchbox > .ico { position: absolute; left: 10px; top: 9px; color: var(--ink-3); width: 16px; height: 16px; }
.searchbox input {
  width: 240px; height: 34px; padding: 0 12px 0 32px;
  border: 1px solid var(--line); border-radius: 9px;
  background: var(--surface-2); outline: none; transition: .16s; font-size: 12.5px;
}
.searchbox input::placeholder { color: #a9b4c4; }
.searchbox input:focus { background: #fff; border-color: #a9c8e8; box-shadow: 0 0 0 3px rgba(47, 125, 209, .1); width: 280px; }
.search-results {
  position: absolute; right: 0; top: 42px; width: 380px; max-height: 420px; overflow: auto;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow-lg); padding: 6px; display: none; z-index: 60;
}
.search-results.open { display: block; }
.sr-item { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.sr-item:hover { background: var(--brand-soft); }
.sr-item .sr-kind { font-size: 10.5px; color: var(--ink-3); border: 1px solid var(--line); border-radius: 5px; padding: 1px 5px; flex: none; }
.sr-item .sr-title { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-item .sr-sub { font-size: 11.5px; color: var(--ink-3); }
.sr-empty { padding: 18px; text-align: center; color: var(--ink-3); font-size: 12.5px; }

.icon-btn {
  width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line);
  background: var(--surface); display: grid; place-items: center; cursor: pointer;
  color: var(--ink-2); transition: .16s; position: relative;
}
.icon-btn:hover { background: var(--surface-2); border-color: #cfd8e4; color: var(--ink); }
.icon-btn.sm { width: 28px; height: 28px; border-radius: 7px; }
.icon-btn.sm .ico { width: 15px; height: 15px; }
.icon-btn.bare { border-color: transparent; background: transparent; }
.icon-btn.bare:hover { background: var(--line-2); }
.bell-dot { position: absolute; top: 7px; right: 8px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); border: 1.5px solid #fff; }

.content { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 22px 26px 60px; scroll-behavior: smooth; }
.content::-webkit-scrollbar, .nav::-webkit-scrollbar, .drawer-body::-webkit-scrollbar, .search-results::-webkit-scrollbar { width: 8px; }
.content::-webkit-scrollbar-thumb, .drawer-body::-webkit-scrollbar-thumb, .search-results::-webkit-scrollbar-thumb { background: #dbe2ec; border-radius: 8px; border: 2px solid transparent; background-clip: content-box; }

/* ============ 通用组件 ============ */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-pad { padding: 16px 18px; }
.section { margin-bottom: 20px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; gap: 12px; }
.section-title { font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 7px; }
.section-title .count { font-size: 11.5px; color: var(--ink-3); font-weight: 500; }
.section-title .ico { width: 15px; height: 15px; color: var(--ink-3); }

.grid { display: grid; gap: 14px; }
.grid > *, .split > *, .cal-wrap > * { min-width: 0; }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 16px; align-items: start; }
@media (max-width: 1180px) { .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .split, .g-2, .g-3 { grid-template-columns: minmax(0, 1fr); } }

.chip {
  display: inline-flex; align-items: center; gap: 4px;
  height: 22px; padding: 0 8px; border-radius: 6px;
  font-size: 11.5px; font-weight: 500; background: var(--line-2); color: var(--ink-2);
  white-space: nowrap;
}
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.chip-red { background: var(--danger-soft); color: var(--danger); }
.chip-blue { background: var(--brand-soft); color: var(--brand-2); }
.chip-green { background: var(--ok-soft); color: var(--ok); }
.chip-amber { background: var(--warn-soft); color: var(--warn); }
.chip-purple { background: #f4f0ff; color: #6941c6; }
.chip-teal { background: #ecfdfb; color: #0e9384; }
.chip-gray { background: #f2f4f7; color: #667085; }
.chip-line { background: #fff; border: 1px solid var(--line); color: var(--ink-2); }

.empty { text-align: center; padding: 42px 20px; color: var(--ink-3); }
.empty .empty-ico { width: 46px; height: 46px; margin: 0 auto 10px; border-radius: 13px; background: var(--surface-2); border: 1px solid var(--line); display: grid; place-items: center; color: #b6c0cf; }
.empty .empty-ico .ico { width: 22px; height: 22px; }
.empty p { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.empty span { font-size: 12px; }

/* 统计卡 */
.stat { padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; position: relative; overflow: hidden; }
.stat-label { font-size: 12px; color: var(--ink-3); display: flex; align-items: center; gap: 6px; }
.stat-value { font-size: 26px; font-weight: 650; letter-spacing: -.6px; line-height: 1; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 12px; font-weight: 500; color: var(--ink-3); margin-left: 3px; letter-spacing: 0; }
.stat-foot { font-size: 11.5px; color: var(--ink-3); }
.stat-ico { position: absolute; right: 12px; top: 12px; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-2); }
.stat-ico .ico { width: 16px; height: 16px; }
.stat.danger .stat-ico { background: var(--danger-soft); color: var(--danger); }
.stat.ok .stat-ico { background: var(--ok-soft); color: var(--ok); }
.stat.amber .stat-ico { background: var(--warn-soft); color: var(--warn); }

/* 任务行 */
.task-list { display: flex; flex-direction: column; }
.task {
  display: flex; align-items: flex-start; gap: 11px;
  padding: 11px 14px; border-bottom: 1px solid var(--line-2);
  transition: background .15s; position: relative;
}
.task:last-child { border-bottom: 0; }
.task:hover { background: var(--surface-2); }
.check {
  width: 18px; height: 18px; border-radius: 50%; flex: none; margin-top: 1.5px;
  border: 1.6px solid #c3ccda; background: #fff; cursor: pointer;
  display: grid; place-items: center; transition: .16s;
}
.check:hover { border-color: var(--brand-2); background: var(--brand-soft); }
.check .ico { width: 11px; height: 11px; stroke-width: 3; color: #fff; opacity: 0; }
.task.done .check { background: var(--brand-2); border-color: var(--brand-2); }
.task.done .check .ico { opacity: 1; }
.task-main { flex: 1; min-width: 0; }
.task-title { font-size: 13.5px; font-weight: 500; line-height: 1.45; word-break: break-word; }
.task.done .task-title { color: var(--ink-3); text-decoration: line-through; }
.task-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 5px; font-size: 11.5px; color: var(--ink-3); }
.task-meta .ico { width: 12.5px; height: 12.5px; }
.task-meta .m { display: inline-flex; align-items: center; gap: 3px; }
.task-meta .m.late { color: var(--danger); font-weight: 500; }
.task-meta .m.today { color: var(--brand-2); font-weight: 500; }
.task-tail { display: flex; align-items: center; gap: 2px; opacity: 0; transition: .15s; }
.task:hover .task-tail { opacity: 1; }
.prio { width: 3px; align-self: stretch; border-radius: 2px; flex: none; margin: -2px 0; }
.prio.high { background: #f04438; }
.prio.medium { background: #f79009; }
.prio.low { background: #84caff; }

/* 开庭卡 */
.hearing-card { padding: 14px 16px; display: flex; gap: 14px; align-items: stretch; }
.hc-date {
  flex: none; width: 58px; border-radius: 10px; background: var(--brand-soft);
  display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 7px 0;
  color: var(--brand); border: 1px solid #dbe9f8;
}
.hc-date.soon { background: var(--danger-soft); border-color: #fadcd8; color: var(--danger); }
.hc-date .d { font-size: 21px; font-weight: 650; line-height: 1; font-variant-numeric: tabular-nums; }
.hc-date .m { font-size: 10.5px; margin-top: 3px; letter-spacing: .05em; }
.hc-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.hc-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hc-title { font-size: 14px; font-weight: 600; }
.hc-info { font-size: 12px; color: var(--ink-2); display: flex; flex-wrap: wrap; gap: 4px 14px; }
.hc-info .m { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); }
.hc-info .m b { font-weight: 500; color: var(--ink-2); }
.hc-info .ico { width: 12.5px; height: 12.5px; }
.countdown {
  flex: none; align-self: center; text-align: right; font-size: 11.5px; color: var(--ink-3);
  border-left: 1px dashed var(--line); padding-left: 14px; min-width: 86px;
}
.countdown b { display: block; font-size: 17px; font-weight: 650; color: var(--danger); letter-spacing: -.3px; font-variant-numeric: tabular-nums; }
.countdown.muted b { color: var(--ink-2); }

/* 日历 */
.cal-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; align-items: start; }
@media (max-width: 1180px) { .cal-wrap { grid-template-columns: minmax(0, 1fr); } }
.cal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.cal-month { font-size: 16px; font-weight: 600; letter-spacing: -.2px; }
.cal-month span { font-size: 12.5px; color: var(--ink-3); font-weight: 500; margin-left: 6px; }
.cal-nav { display: flex; gap: 4px; align-items: center; }
.cal-week { display: grid; grid-template-columns: repeat(7, 1fr); border-bottom: 1px solid var(--line); }
.cal-week div { text-align: center; font-size: 11.5px; color: var(--ink-3); font-weight: 500; padding: 8px 0; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.cal-cell {
  min-height: 96px; border-right: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2);
  padding: 6px 7px; display: flex; flex-direction: column; gap: 3px; cursor: pointer;
  transition: background .14s; position: relative;
}
.cal-cell:nth-child(7n) { border-right: 0; }
.cal-cell:hover { background: var(--surface-2); }
.cal-cell.out { background: #fbfcfd; }
.cal-cell.out .cal-day { color: #c2cbd8; }
.cal-cell.sel { background: var(--brand-soft); box-shadow: inset 0 0 0 1.5px #a9c8e8; }
.cal-day { font-size: 12.5px; font-weight: 500; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; font-variant-numeric: tabular-nums; }
.cal-cell.today .cal-day { background: var(--brand); color: #fff; font-weight: 600; }
.cal-cell.out .cal-day { font-weight: 400; }
.cal-ev {
  font-size: 10.5px; line-height: 1.35; padding: 1.5px 5px; border-radius: 4px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  border-left: 2px solid var(--brand-2); background: var(--brand-soft); color: #185b96;
}
.cal-ev.ev-hearing { border-color: var(--danger); background: var(--danger-soft); color: #b42318; }
.cal-ev.ev-deadline { border-color: var(--warn); background: var(--warn-soft); color: #93370d; }
.cal-ev.ev-done { border-color: #b9c2cf; background: #f4f6f9; color: #8a97a9; text-decoration: line-through; }
.cal-more { font-size: 10.5px; color: var(--ink-3); padding-left: 4px; }
.cal-legend { display: flex; gap: 14px; padding: 10px 16px; border-top: 1px solid var(--line-2); font-size: 11.5px; color: var(--ink-3); }
.cal-legend span { display: inline-flex; align-items: center; gap: 5px; }
.cal-legend i { width: 7px; height: 7px; border-radius: 2px; display: inline-block; }

.day-panel { position: sticky; top: 0; }
.day-head { padding: 14px 16px; border-bottom: 1px solid var(--line-2); }
.day-head .dh-date { font-size: 15px; font-weight: 600; }
.day-head .dh-sub { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.day-body { padding: 8px; max-height: 560px; overflow: auto; }
.day-item { display: flex; gap: 9px; padding: 9px 10px; border-radius: 8px; cursor: pointer; }
.day-item:hover { background: var(--surface-2); }
.day-time { font-size: 11.5px; color: var(--ink-3); width: 40px; flex: none; font-variant-numeric: tabular-nums; padding-top: 1px; }
.day-txt { font-size: 12.5px; line-height: 1.45; }
.day-txt small { display: block; font-size: 11px; color: var(--ink-3); }
.day-bar { width: 3px; border-radius: 2px; background: var(--brand-2); flex: none; }
.day-bar.hearing { background: var(--danger); }
.day-bar.deadline { background: var(--warn); }

/* 案件 */
.case-card { padding: 15px 16px; cursor: pointer; transition: .16s; display: flex; flex-direction: column; gap: 9px; }
.case-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); border-color: #d5e2f0; }
.cc-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.cc-name { font-size: 14px; font-weight: 600; line-height: 1.4; }
.cc-no { font-size: 11.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; margin-top: 2px; }
.cc-meta { display: flex; flex-wrap: wrap; gap: 5px 14px; font-size: 12px; color: var(--ink-2); }
.cc-meta .m { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); }
.cc-meta .m b { font-weight: 500; color: var(--ink-2); }
.cc-meta .ico { width: 12.5px; height: 12.5px; }
.cc-foot { display: flex; align-items: center; justify-content: space-between; padding-top: 9px; border-top: 1px dashed var(--line); font-size: 11.5px; color: var(--ink-3); }
.cc-progress { display: flex; align-items: center; gap: 7px; }
.bar { height: 4px; border-radius: 3px; background: var(--line-2); width: 80px; overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, #6fb0ea, #2f7dd1); }

.toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; padding: 2px; gap: 2px; }
.seg button {
  height: 28px; padding: 0 11px; border: 0; background: transparent; border-radius: 7px;
  font-size: 12.5px; color: var(--ink-2); cursor: pointer; font-weight: 500; white-space: nowrap;
}
.seg button.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.seg button:hover:not(.on) { background: var(--line-2); }
.field-inline { position: relative; }
.field-inline select, .toolbar select {
  height: 32px; border: 1px solid var(--line); border-radius: 8px; background: #fff;
  padding: 0 26px 0 10px; font-size: 12.5px; color: var(--ink-2); outline: none; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a97a9' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 9px center;
}
.toolbar select:focus { border-color: #a9c8e8; box-shadow: 0 0 0 3px rgba(47, 125, 209, .1); }

/* 表格 */
.table { width: 100%; border-collapse: collapse; }
.table th {
  text-align: left; font-size: 11.5px; font-weight: 500; color: var(--ink-3);
  padding: 9px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2);
  white-space: nowrap;
}
.table td { padding: 11px 14px; border-bottom: 1px solid var(--line-2); font-size: 13px; vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: var(--surface-2); }
.table .num { font-variant-numeric: tabular-nums; color: var(--ink-2); }
.table .row-link { font-weight: 500; cursor: pointer; }
.table .row-link:hover { color: var(--brand-2); }

/* 法院通讯录 */
.court-item { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; overflow: hidden; margin-bottom: 10px; box-shadow: var(--shadow-sm); }
.court-head { display: flex; align-items: center; gap: 12px; padding: 13px 16px; cursor: pointer; }
.court-head:hover { background: var(--surface-2); }
.court-ico { width: 34px; height: 34px; border-radius: 9px; background: linear-gradient(150deg, #f7f3ea, #efe6d5); color: var(--gold); display: grid; place-items: center; flex: none; }
.court-ico .ico { width: 17px; height: 17px; }
.court-name { font-size: 13.5px; font-weight: 600; }
.court-sub { font-size: 11.5px; color: var(--ink-3); margin-top: 1px; display: flex; gap: 10px; flex-wrap: wrap; }
.court-head .chev { margin-left: auto; color: #b0bccb; transition: transform .2s; }
.court-item.open .chev { transform: rotate(90deg); }
.court-body { display: none; border-top: 1px solid var(--line-2); padding: 4px 16px 12px; background: var(--surface-2); }
.court-item.open .court-body { display: block; }
.person { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.person:last-child { border-bottom: 0; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none; display: grid; place-items: center;
  font-size: 12px; font-weight: 600; color: #fff; background: linear-gradient(140deg, #6b8fb8, #3c648f);
}
.avatar.a2 { background: linear-gradient(140deg, #b58b6b, #8f6442); }
.avatar.a3 { background: linear-gradient(140deg, #6b9c8a, #457a67); }
.avatar.a4 { background: linear-gradient(140deg, #9080b5, #66548f); }
.person-main { flex: 1; min-width: 0; }
.person-name { font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 7px; }
.person-meta { font-size: 11.5px; color: var(--ink-3); }
.person-acts { display: flex; gap: 4px; }
.tel-link { display: inline-flex; align-items: center; gap: 4px; color: var(--brand-2); font-variant-numeric: tabular-nums; }
.tel-link:hover { text-decoration: underline; }

/* 附件 */
.drop-zone {
  border: 1.5px dashed #cbd6e4; border-radius: var(--radius); background: var(--surface-2);
  padding: 26px; text-align: center; transition: .18s; cursor: pointer; margin-bottom: 14px;
}
.drop-zone:hover, .drop-zone.over { border-color: var(--brand-2); background: #f3f8fe; }
.drop-zone .ico { width: 26px; height: 26px; color: #9fb0c6; margin-bottom: 6px; stroke-width: 1.5; }
.drop-zone b { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.drop-zone p { font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.file-card { padding: 12px 13px; display: flex; gap: 10px; align-items: center; position: relative; }
.file-ext { width: 34px; height: 38px; border-radius: 7px; flex: none; display: grid; place-items: center; font-size: 9.5px; font-weight: 700; letter-spacing: .02em; color: #fff; background: #8a97a9; }
.file-ext.pdf { background: #d9534f; } .file-ext.doc, .file-ext.docx { background: #2b579a; }
.file-ext.xls, .file-ext.xlsx { background: #217346; } .file-ext.jpg, .file-ext.png, .file-ext.jpeg { background: #7b5ea7; }
.file-info { min-width: 0; flex: 1; }
.file-name { font-size: 12.5px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-sub { font-size: 11px; color: var(--ink-3); margin-top: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-acts { display: flex; gap: 1px; opacity: 0; transition: .15s; }
.file-card:hover .file-acts { opacity: 1; }

/* 时间轴 */
.timeline { position: relative; padding-left: 22px; }
.timeline::before { content: ""; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 1.5px; background: var(--line); }
.tl-item { position: relative; padding-bottom: 16px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: ""; position: absolute; left: -21px; top: 4px; width: 9px; height: 9px; border-radius: 50%;
  background: #fff; border: 2px solid #c3ccda;
}
.tl-item.hearing::before { border-color: var(--danger); background: var(--danger); }
.tl-item.task::before { border-color: var(--brand-2); }
.tl-item.done::before { border-color: var(--ok); background: var(--ok); }
.tl-date { font-size: 11.5px; color: var(--ink-3); margin-bottom: 2px; }
.tl-title { font-size: 13px; font-weight: 500; }
.tl-sub { font-size: 11.5px; color: var(--ink-3); }

/* 弹窗 */
.modal-mask, .drawer-mask {
  position: fixed; inset: 0; background: rgba(15, 31, 51, .32); backdrop-filter: blur(2px);
  z-index: 100; display: flex; align-items: center; justify-content: center; padding: 24px;
  animation: fade .16s ease;
}
.modal-mask[hidden], .drawer-mask[hidden], .drawer[hidden], .bell-dot[hidden] { display: none !important; }
.drawer-mask { z-index: 90; justify-content: flex-end; padding: 0; }
@keyframes fade { from { opacity: 0 } }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.985) } }
.modal {
  width: 100%; max-width: 560px; max-height: 88vh; background: #fff; border-radius: 16px;
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column; animation: pop .18s ease;
  overflow: hidden;
}
.modal.wide { max-width: 720px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid var(--line-2); }
.modal-head h2 { font-size: 15.5px; font-weight: 600; }
.modal-body { padding: 18px; overflow-y: auto; }
.modal-foot { padding: 13px 18px; border-top: 1px solid var(--line-2); display: flex; justify-content: flex-end; gap: 8px; background: var(--surface-2); }

.form-row { display: grid; gap: 4px; margin-bottom: 13px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.form-grid .span2 { grid-column: span 2; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } .form-grid .span2 { grid-column: auto; } }
label.lbl { font-size: 12px; font-weight: 500; color: var(--ink-2); }
label.lbl .req { color: var(--danger); margin-left: 2px; }
.inp, textarea.inp, select.inp {
  width: 100%; height: 36px; padding: 0 11px; border: 1px solid var(--line);
  border-radius: 8px; background: #fff; outline: none; transition: .15s; font-size: 13px;
}
textarea.inp { height: auto; padding: 8px 11px; resize: vertical; min-height: 66px; line-height: 1.55; }
.inp:focus, select.inp:focus { border-color: #a9c8e8; box-shadow: 0 0 0 3px rgba(47, 125, 209, .1); }
select.inp {
  appearance: none; padding-right: 28px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a97a9' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
}
.hint { font-size: 11.5px; color: var(--ink-3); }
.prio-pick { display: flex; gap: 6px; }
.prio-pick button {
  flex: 1; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: #fff;
  font-size: 12.5px; cursor: pointer; color: var(--ink-2); display: inline-flex; align-items: center; justify-content: center; gap: 5px;
}
.prio-pick button .dot { width: 7px; height: 7px; border-radius: 50%; }
.prio-pick button.on { border-color: currentColor; background: var(--surface-2); font-weight: 600; }
.prio-pick button[data-p="high"].on { color: var(--danger); }
.prio-pick button[data-p="medium"].on { color: var(--warn); }
.prio-pick button[data-p="low"].on { color: var(--brand-2); }
.prio-pick button[data-p="none"].on { color: var(--ink-2); }

/* 抽屉 */
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: 640px; max-width: 94vw;
  background: #fff; z-index: 95; box-shadow: -20px 0 60px -20px rgba(15, 31, 51, .3);
  display: flex; flex-direction: column; animation: slideIn .2s ease;
}
@keyframes slideIn { from { transform: translateX(24px); opacity: .6 } }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 18px; border-bottom: 1px solid var(--line-2); gap: 10px; }
.drawer-head h2 { font-size: 15px; font-weight: 600; }
.drawer-body { padding: 18px; overflow-y: auto; flex: 1; }

.detail-hero { padding-bottom: 14px; border-bottom: 1px solid var(--line-2); margin-bottom: 14px; }
.detail-title { font-size: 18px; font-weight: 650; letter-spacing: -.3px; line-height: 1.35; }
.detail-sub { font-size: 12px; color: var(--ink-3); margin-top: 4px; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.detail-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.kv { display: grid; grid-template-columns: 84px 1fr; gap: 9px 12px; font-size: 12.5px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; color: var(--ink); word-break: break-word; }
.block-title { font-size: 12px; font-weight: 600; color: var(--ink-2); margin: 18px 0 8px; display: flex; align-items: center; justify-content: space-between; }
.block-title .ico { width: 13px; height: 13px; color: var(--ink-3); }

/* toast */
.toasts { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 9px; padding: 10px 16px; border-radius: 10px;
  background: #10243a; color: #fff; font-size: 12.5px; box-shadow: 0 12px 32px -8px rgba(15, 31, 51, .5);
  animation: toastIn .22s ease; max-width: 420px;
}
@keyframes toastIn { from { opacity: 0; transform: translateY(8px) } }
.toast .ico { width: 15px; height: 15px; color: #6ee7b7; }
.toast.warn .ico { color: #fbbf24; }
.toast.bad .ico { color: #fca5a5; }
.toast.fade { opacity: 0; transition: .3s; }

/* 通知中心 */
.notif-list { display: flex; flex-direction: column; }
.notif { display: flex; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line-2); }
.notif:last-child { border-bottom: 0; }
.notif-ico { width: 28px; height: 28px; border-radius: 8px; flex: none; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-2); }
.notif-ico.danger { background: var(--danger-soft); color: var(--danger); }
.notif-ico .ico { width: 14px; height: 14px; }
.notif-txt { font-size: 12.5px; line-height: 1.5; }
.notif-txt small { display: block; font-size: 11px; color: var(--ink-3); margin-top: 1px; }

.switch { position: relative; width: 38px; height: 22px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch i { position: absolute; inset: 0; background: #d7dee8; border-radius: 20px; transition: .2s; cursor: pointer; }
.switch i::after { content: ""; position: absolute; width: 16px; height: 16px; border-radius: 50%; background: #fff; top: 3px; left: 3px; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + i { background: var(--brand-2); }
.switch input:checked + i::after { transform: translateX(16px); }

.set-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line-2); }
.set-row:last-child { border-bottom: 0; }
.set-row .sr-title { font-size: 13px; font-weight: 500; }
.set-row .sr-desc { font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #dbe2ec; border-radius: 8px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-track { background: transparent; }

@media (max-width: 860px) {
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; z-index: 80; transform: translateX(-100%); transition: .22s; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: none; }
  .searchbox input { width: 140px; }
  .searchbox input:focus { width: 180px; }
  .content { padding: 16px; }
  .topbar { padding: 0 14px; }
  .cal-cell { min-height: 70px; }
  .cal-ev { font-size: 9px; }
}

/* ============ 补充 ============ */
.topbar-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.menu-btn { display: none; }
@media (max-width: 860px) { .menu-btn { display: grid; } }

.qa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 560px) { .qa-grid { grid-template-columns: 1fr; } }
.qa-item {
  display: flex; align-items: flex-start; gap: 11px; padding: 14px;
  border: 1px solid var(--line); border-radius: 11px; background: #fff;
  cursor: pointer; transition: .16s; text-align: left; width: 100%;
}
.qa-item:hover { border-color: #b9d3ec; background: #fbfdff; box-shadow: 0 4px 14px -8px rgba(27, 75, 122, .4); }
.qa-ico { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; flex: none; background: var(--brand-soft); color: var(--brand-2); }
.qa-ico.red { background: var(--danger-soft); color: var(--danger); }
.qa-ico.amber { background: var(--warn-soft); color: var(--warn); }
.qa-ico.green { background: var(--ok-soft); color: var(--ok); }
.qa-ico .ico { width: 17px; height: 17px; }
.qa-t { font-size: 13px; font-weight: 600; }
.qa-d { font-size: 11.5px; color: var(--ink-3); margin-top: 1px; line-height: 1.5; }

.kbd {
  display: inline-block; padding: 1px 5px; border-radius: 4px; border: 1px solid var(--line);
  border-bottom-width: 2px; background: var(--surface-2); font-size: 10.5px; color: var(--ink-3);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ============ 隐藏属性统一生效 ============ */
[hidden] { display: none !important; }

/* ============ 登录页 ============ */
.auth-gate {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  background:
    radial-gradient(900px 520px at 12% 8%, #e8f1fb 0%, rgba(244, 246, 249, 0) 60%),
    radial-gradient(760px 460px at 88% 92%, #f4efe6 0%, rgba(244, 246, 249, 0) 62%),
    var(--bg);
  overflow: auto;
}
.auth-wrap { width: 100%; max-width: 392px; }
.auth-card {
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  padding: 26px 26px 22px; box-shadow: var(--shadow-md);
}
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.auth-brand img { width: 46px; height: 46px; border-radius: 11px; object-fit: cover; box-shadow: 0 4px 12px -6px rgba(27, 75, 122, .5); }
.auth-brand strong { display: block; font-size: 16.5px; letter-spacing: -.2px; }
.auth-brand span { display: block; font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
.auth-tabs { display: flex; gap: 4px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; margin-bottom: 16px; }
.auth-tabs button {
  flex: 1; border: 0; background: transparent; border-radius: 8px;
  padding: 7px 0; font-size: 12.5px; color: var(--ink-2); cursor: pointer;
}
.auth-tabs button.on { background: #fff; color: var(--brand); font-weight: 600; box-shadow: var(--shadow-sm); }
.auth-field { margin-bottom: 12px; }
.auth-field label { display: block; font-size: 11.5px; color: var(--ink-3); margin-bottom: 5px; }
.auth-field .inp { width: 100%; height: 40px; }
.auth-code { display: flex; gap: 8px; }
.auth-code .inp { flex: 1; letter-spacing: .18em; }
.auth-code .btn { flex: none; height: 40px; min-width: 96px; justify-content: center; }
.auth-err {
  margin-top: 10px; padding: 9px 11px; border-radius: 9px; font-size: 12px; line-height: 1.6;
  background: var(--danger-soft); border: 1px solid #f6d5d1; color: #b42318;
}
.auth-note { margin-top: 16px; font-size: 11.5px; color: var(--ink-3); line-height: 1.75; }
.auth-state { text-align: center; padding: 8px 0 16px; }
.auth-state-ico {
  width: 46px; height: 46px; border-radius: 50%; margin: 0 auto 12px;
  display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-2);
}
.auth-state-ico .ico { width: 22px; height: 22px; }
.auth-state h3 { font-size: 15px; margin-bottom: 8px; }
.auth-state p { font-size: 12.5px; color: var(--ink-2); line-height: 1.75; }
.auth-id {
  display: inline-block; margin-top: 12px; padding: 4px 10px; border-radius: 20px;
  background: var(--surface-2); border: 1px solid var(--line); font-size: 12px; color: var(--ink-2);
}

/* ============ 侧栏账号 ============ */
.me-card { border-top: 1px solid var(--line-2); padding-top: 12px; }
.me-row { display: flex; align-items: center; gap: 9px; }
.me-avatar {
  width: 30px; height: 30px; border-radius: 9px; flex: none;
  display: grid; place-items: center; font-size: 13px; font-weight: 600; color: #fff;
  background: linear-gradient(140deg, #1b4b7a, #2f7dd1);
  font-family: "Songti SC", "STSong", serif;
}
.me-info { min-width: 0; flex: 1; }
.me-name { font-size: 12.5px; font-weight: 600; display: flex; align-items: center; gap: 5px; }
.me-tag {
  font-size: 9.5px; font-weight: 500; color: var(--gold); border: 1px solid #eadcc4;
  background: #fdf8ef; border-radius: 4px; padding: 0 4px; line-height: 14px;
}
.me-sub { font-size: 10.5px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me-sync {
  display: flex; align-items: center; gap: 5px; margin-top: 8px; cursor: pointer;
  font-size: 10.5px; color: var(--ink-3);
}
.me-sync .ico { width: 13px; height: 13px; }
.me-sync:hover { color: var(--brand-2); }

/* ============ 法规库 ============ */
.law-card { padding: 14px 15px; cursor: pointer; transition: .16s; display: flex; flex-direction: column; gap: 7px; }
.law-card:hover { border-color: #c7dcf3; box-shadow: var(--shadow-md); transform: translateY(-1px); }
.law-top { display: flex; align-items: center; gap: 6px; }
.law-article { font-size: 11.5px; color: var(--brand); font-weight: 600; }
.law-owner { margin-left: auto; font-size: 10.5px; color: var(--ink-3); }
.law-title { font-size: 13.5px; font-weight: 600; letter-spacing: -.1px; line-height: 1.45; }
.law-excerpt { font-size: 12px; color: var(--ink-2); line-height: 1.65; }
.law-foot { display: flex; align-items: center; gap: 8px; font-size: 10.5px; color: var(--ink-3); margin-top: 2px; }
.law-foot .ico { width: 12px; height: 12px; vertical-align: -2px; }
.law-body {
  font-size: 12.5px; line-height: 1.95; color: #26374d; white-space: pre-wrap;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px;
  padding: 14px 15px; font-family: "Songti SC", "STSong", "PingFang SC", serif;
}
.law-note {
  font-size: 12.5px; line-height: 1.8; color: #7a4a10;
  background: var(--warn-soft); border: 1px solid #fdecc8; border-radius: 10px; padding: 11px 13px;
}

/* ============ 团队案件 ============ */
.team-card { padding: 15px 16px; cursor: pointer; transition: .16s; }
.team-card:hover { border-color: #c7dcf3; box-shadow: var(--shadow-md); transform: translateY(-1px); }
.tc-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.tc-name { font-size: 13.5px; font-weight: 600; line-height: 1.45; }
.tc-no { font-size: 11px; color: var(--ink-3); margin-top: 2px; }
.tc-parties {
  display: flex; align-items: stretch; gap: 8px; margin: 12px 0 10px;
  background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 10px; padding: 9px 11px;
}
.tc-party { flex: 1; min-width: 0; }
.tc-party span { display: block; font-size: 10.5px; color: var(--ink-3); }
.tc-party b { display: block; font-size: 12.5px; font-weight: 600; margin-top: 1px; overflow: hidden; text-overflow: ellipsis; }
.tc-vs { display: grid; place-items: center; font-size: 10.5px; color: #b6c0cf; padding: 0 2px; }
.tc-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 11.5px; color: var(--ink-3); }
.tc-meta .m { display: inline-flex; align-items: center; gap: 4px; }
.tc-meta .m .ico { width: 13px; height: 13px; }
.tc-lock {
  margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--line);
  font-size: 10.5px; color: var(--ink-3); display: flex; align-items: center; gap: 5px;
}
.tc-lock .ico { width: 12px; height: 12px; }
.privacy-box {
  margin-top: 16px; padding: 12px 14px; border-radius: 10px;
  background: var(--brand-soft); border: 1px solid #d8e7f8; font-size: 12px; color: #2c557f; line-height: 1.75;
}
.privacy-box b { display: block; font-size: 12.5px; margin-bottom: 3px; }
.privacy-inline {
  display: flex; align-items: flex-start; gap: 6px; margin: 12px 0 4px;
  padding: 8px 10px; border-radius: 8px; background: var(--surface-2);
  border: 1px dashed var(--line); font-size: 11px; color: var(--ink-3); line-height: 1.6;
}
.privacy-inline .ico { width: 13px; height: 13px; margin-top: 1px; }

/* ============ 开庭表单·随案附件 ============ */
.att-list, .att-pending { display: flex; flex-direction: column; gap: 6px; }
.att-pending:not(:empty) { margin-bottom: 8px; }
.att-list:not(:empty) { margin-bottom: 8px; }
.att-item {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px;
  background: var(--surface-2); transition: .16s;
}
.att-item.pending { border-style: dashed; border-color: #b9d3ec; background: #f6fbff; }
.att-item.mark-del { opacity: .55; border-color: #f2c6c2; background: var(--danger-soft); }
.att-item.mark-del .att-name { text-decoration: line-through; }
.att-ext {
  width: 30px; height: 32px; border-radius: 6px; flex: none;
  display: grid; place-items: center; font-size: 8.5px; font-weight: 700; color: #fff;
  background: #8a97a9; letter-spacing: .02em;
}
.att-ext.pdf { background: #d9534f; }
.att-ext.doc, .att-ext.docx { background: #2b579a; }
.att-ext.xls, .att-ext.xlsx { background: #217346; }
.att-ext.jpg, .att-ext.png, .att-ext.jpeg, .att-ext.gif { background: #7b5ea7; }
.att-name { flex: 1; min-width: 0; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-size { font-size: 11px; color: var(--ink-3); flex: none; }
.att-del {
  flex: none; border: 0; background: transparent; cursor: pointer;
  font-size: 15px; line-height: 1; color: #a3aec0; padding: 2px 4px; border-radius: 5px;
}
.att-del:hover { color: var(--danger); background: #fdecea; }
.att-item .att-del[data-att-del] { font-size: 11.5px; }
.att-drop {
  display: flex; align-items: center; gap: 11px; cursor: pointer;
  padding: 13px 14px; border: 1.5px dashed #cbd6e4; border-radius: 10px;
  background: var(--surface-2); transition: .18s;
}
.att-drop:hover, .att-drop.over { border-color: var(--brand-2); background: #f3f8fe; }
.att-drop .ico { width: 20px; height: 20px; color: #9fb0c6; flex: none; stroke-width: 1.7; }
.att-drop-txt { min-width: 0; }
.att-drop-txt b { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.att-drop-txt span { display: block; font-size: 11px; color: var(--ink-3); margin-top: 2px; line-height: 1.5; }

/* ============ 表单补充：期限与提示 ============ */
.form-sub {
  margin: 16px 0 10px; padding-top: 12px; border-top: 1px dashed var(--line);
  font-size: 12px; font-weight: 600; color: var(--ink-2); letter-spacing: .02em;
}
.lbl-tip { font-weight: 400; font-size: 10.5px; color: var(--ink-3); margin-left: 6px; }
.dl-preview {
  margin: 2px 0 12px; padding: 10px 12px; border-radius: 9px;
  background: var(--brand-soft); border: 1px solid #d8e7f8;
  font-size: 11.5px; color: #2c557f; line-height: 1.8;
}
.dl-preview .muted { color: var(--ink-3); }
.dl-row { display: flex; gap: 8px; }
.dl-row > span { flex: none; width: 62px; color: #5b7899; }
.dl-row b.urgent { color: #d92d20; }
.dl-row b.soon { color: #b25e09; }
.dl-row b.past { color: #8a97a9; text-decoration: line-through; }
.chk { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-2); height: 34px; }
.chk input { width: 15px; height: 15px; accent-color: var(--brand-2); }

/* ============ 诉讼期限卡片 ============ */
.dl-card { border: 1px solid var(--line); border-radius: 11px; padding: 11px 13px; margin: 12px 0 14px; background: #fff; }
.dl-card.plain { font-size: 11.5px; color: var(--ink-3); background: var(--surface-2); border-style: dashed; display: flex; align-items: center; gap: 6px; }
.dl-card .ico { width: 14px; height: 14px; vertical-align: -2px; }
.dl-head { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; margin-bottom: 8px; }
.dl-rule { margin-left: auto; font-weight: 400; font-size: 10.5px; color: var(--ink-3); }
.dl-item { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: 12px; }
.dl-item > span { width: 62px; flex: none; color: var(--ink-3); font-size: 11.5px; }
.dl-item > div { flex: 1; min-width: 0; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.dl-item b { font-weight: 600; }
.dl-item b.urgent, .dl-left.urgent { color: #d92d20; }
.dl-item b.soon, .dl-left.soon { color: #b25e09; }
.dl-item b.past, .dl-left.past { color: var(--ink-3); }
.dl-left { font-size: 10.5px; padding: 1px 6px; border-radius: 20px; background: var(--surface-2); color: var(--ink-2); }
.dl-left.urgent { background: var(--danger-soft); }
.dl-left.soon { background: var(--warn-soft); }
.dl-mini { display: flex; align-items: center; gap: 10px; padding: 10px 12px; cursor: pointer; }
.dl-mini:hover { border-color: #c7dcf3; box-shadow: var(--shadow-md); }
.dm-left { min-width: 0; flex: 1; }
.dm-kind { font-size: 10px; color: #b42318; background: var(--danger-soft); border-radius: 4px; padding: 0 5px; margin-right: 6px; }
.dm-left b { font-size: 12.5px; font-weight: 600; }
.dm-date { display: block; font-size: 10.5px; color: var(--ink-3); margin-top: 2px; }

/* ============ 案件材料与证据目录 ============ */
.att-group { margin-bottom: 12px; border: 1px solid var(--line); border-radius: 11px; overflow: hidden; background: #fff; }
.att-group-head {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  background: var(--surface-2); border-bottom: 1px solid var(--line-2); font-size: 12px; font-weight: 600;
}
.att-group-head i { font-style: normal; font-weight: 500; color: var(--ink-3); font-size: 10.5px; }
.att-group-head .btn { margin-left: auto; }
.att-group > .card.file-card { margin: 0 !important; border: 0; border-bottom: 1px dashed var(--line-2); border-radius: 0; }
.att-group > .card.file-card:last-child { border-bottom: 0; }
.att-empty { padding: 11px 12px; font-size: 11.5px; color: #a3aec0; }
.ev-block { border: 1px solid #e3ecf7; border-radius: 11px; background: #fff; padding: 11px 12px; margin-bottom: 14px; }
.ev-head { display: flex; align-items: center; gap: 6px; font-size: 12px; margin-bottom: 9px; }
.ev-head .ico { width: 14px; height: 14px; color: var(--brand-2); }
.ev-table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.ev-table th, .ev-table td { border: 1px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; }
.ev-table th { background: var(--surface-2); font-weight: 600; color: var(--ink-2); }
.ev-table td.num { text-align: center; }
.ev-note { font-size: 10.5px; color: var(--ink-3); margin-top: 7px; line-height: 1.6; }
.ev-table .muted { color: #b6c0cf; }
.archive-box {
  display: flex; align-items: center; gap: 10px; margin-top: 18px;
  padding: 12px 14px; border-radius: 11px; border: 1px dashed var(--line); background: var(--surface-2);
}
.archive-box.on { border-style: solid; border-color: #c7e8d5; background: var(--ok-soft); }
.ab-main { flex: 1; min-width: 0; font-size: 12px; color: var(--ink-2); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ab-main .ico { width: 15px; height: 15px; color: var(--ink-3); }
.ab-main b { font-size: 12.5px; }
.ab-main span { font-size: 11px; color: var(--ink-3); }
.archive-box.on .ab-main .ico { color: var(--ok); }

/* ============ 知识库 ============ */
.know-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.know-card { padding: 15px 16px; cursor: pointer; display: flex; flex-direction: column; gap: 8px; transition: .16s; }
.know-card:hover { border-color: #c7dcf3; box-shadow: var(--shadow-md); transform: translateY(-1px); }
.know-top { display: flex; align-items: center; gap: 6px; }
.know-owner { margin-left: auto; font-size: 10.5px; color: var(--ink-3); }
.know-title { font-size: 14px; font-weight: 600; line-height: 1.5; letter-spacing: -.1px; }
.know-summary { font-size: 12px; color: var(--ink-2); line-height: 1.65; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.know-foot { display: flex; align-items: center; gap: 6px; font-size: 10.5px; color: var(--ink-3); margin-top: 2px; flex-wrap: wrap; }
.know-foot .ico { width: 12px; height: 12px; vertical-align: -2px; }
.know-foot .tag { background: var(--brand-soft); color: #2c557f; border-radius: 4px; padding: 1px 6px; }
.know-body {
  font-size: 13px; line-height: 1.95; color: #26374d; white-space: pre-wrap;
  font-family: "Songti SC", "STSong", "PingFang SC", serif;
  background: #fff; border: 1px solid var(--line); border-radius: 11px; padding: 16px 17px;
}

/* ============ 计算工具 ============ */
.tool-tabs { margin-bottom: 16px; }
.calc-total {
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  padding: 12px 14px; border-radius: 11px; background: linear-gradient(120deg, #eef5fd, #f8fbff);
  border: 1px solid #ddeafa; margin-bottom: 12px;
}
.calc-total > span { font-size: 11.5px; color: #5b7899; }
.calc-total > b { font-size: 22px; font-weight: 650; letter-spacing: -.6px; color: #1b4b7a; }
.calc-total > i { font-style: normal; font-size: 11px; color: #8a97a9; width: 100%; }
.calc-table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.calc-table th, .calc-table td { border-bottom: 1px solid var(--line-2); padding: 7px 6px; text-align: left; }
.calc-table th { color: var(--ink-3); font-weight: 500; font-size: 10.5px; }
.calc-table td.num { text-align: right; }
.calc-note { font-size: 10px; color: var(--ink-3); margin-top: 2px; }
.calc-hint { margin-top: 12px; font-size: 11px; color: var(--ink-3); line-height: 1.7; }
.calc-range > b { font-size: 17px; }
.calc-items td.expr { font-size: 10.5px; color: var(--ink-3); }
.calc-items td:first-child { width: 34%; }

/* ============ 共享条目：录入人标记 ============ */
.ro-owner { font-size: 10.5px; color: var(--ink-3); display: inline-flex; align-items: center; gap: 3px; }
.ro-owner .ico { width: 11px; height: 11px; }
.ro-tip { font-size: 11px; color: #b54708; background: #fff8ec; border: 1px solid #f6e0b5; border-radius: 7px; padding: 5px 9px; }

/* ============ 操作日志 ============ */
.audit-hint { font-size: 11.5px; color: var(--ink-3); line-height: 1.7; background: #f7f9fc; border: 1px solid var(--line-2); border-radius: 9px; padding: 9px 11px; margin-bottom: 12px; display: flex; gap: 6px; align-items: flex-start; }
.audit-hint .ico { width: 13px; height: 13px; margin-top: 2px; flex: none; }
.audit-filters { margin-bottom: 10px; }
.audit-filters .seg { flex-wrap: wrap; }
.audit-list { display: flex; flex-direction: column; gap: 2px; }
.audit-day { font-size: 11px; font-weight: 600; color: var(--ink-3); margin: 14px 0 4px; padding-left: 2px; }
.audit-day:first-child { margin-top: 0; }
.audit-row { display: flex; gap: 10px; padding: 8px 2px; border-bottom: 1px solid var(--line-2); }
.audit-row:last-child { border-bottom: 0; }
.audit-time { font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; min-width: 40px; padding-top: 1px; }
.audit-main { min-width: 0; flex: 1; }
.audit-line { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-1); }
.audit-line b { font-weight: 600; }
.audit-line .chip { height: 18px; font-size: 10.5px; }
.audit-obj { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.audit-sub { font-size: 11px; color: var(--ink-3); margin-top: 2px; line-height: 1.6; }

/* ============ 条文内查找 ============ */
.law-find {
  display: flex; align-items: center; gap: 8px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 9px;
  padding: 7px 10px; margin-bottom: 12px;
}
.law-find .ico { width: 13px; height: 13px; color: var(--ink-3); flex: none; }
.law-find input {
  flex: 1; min-width: 0; border: 0; outline: 0; background: transparent;
  font-size: 12.5px; color: var(--ink-1);
}
.law-find input::placeholder { color: var(--ink-3); }
.law-find-cnt { font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.law-find-nav { display: flex; gap: 2px; }
.law-find-nav .icon-btn.sm { width: 24px; height: 24px; }
.law-find-nav .ico { width: 13px; height: 13px; }
mark.law-hit { background: #fdeeb8; color: inherit; border-radius: 3px; padding: 0 1px; }
mark.law-hit.cur { background: #f5b942; color: #3a2a00; }

/* ============ 可输入下拉框（开庭类型） ============ */
.combo { position: relative; }
.combo-inp { padding-right: 30px !important; }
.combo-btn {
  position: absolute; top: 1px; right: 1px; bottom: 1px; width: 28px;
  display: flex; align-items: center; justify-content: center;
  border: 0; background: transparent; cursor: pointer; border-radius: 0 8px 8px 0;
}
.combo-btn::after {
  content: ""; width: 0; height: 0; border-left: 4.5px solid transparent;
  border-right: 4.5px solid transparent; border-top: 5px solid var(--ink-3);
  transition: transform .15s;
}
.combo.open .combo-btn::after { transform: rotate(180deg); }
.combo-btn:hover::after { border-top-color: var(--ink-2); }
.combo-pop {
  position: absolute; z-index: 80; top: calc(100% + 4px); left: 0; right: 0;
  max-height: 208px; overflow: auto; padding: 4px;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  box-shadow: 0 10px 26px rgba(16, 24, 40, .14);
}
.combo-opt, .combo-empty {
  padding: 7px 10px; border-radius: 7px; font-size: 12.5px; color: var(--ink-1);
  cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.combo-opt:hover, .combo-opt.on { background: var(--surface-2); }
.combo-opt[hidden] { display: none; }
.combo-empty { color: #2f7dd1; font-size: 12px; border-top: 1px dashed var(--line); margin-top: 3px; padding-top: 8px; }
.combo-empty[hidden] { display: none; }

/* ============ 案件协作 ============ */
.collab-inline {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 12px; margin-bottom: 14px;
  background: var(--brand-soft); border: 1px solid #d6e5f6; border-radius: var(--radius-sm);
  font-size: 12px; color: var(--brand);
}
.collab-inline .ico { width: 15px; height: 15px; }

.collab-team {
  padding: 12px 14px; margin-bottom: 16px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius);
}
.ct-head {
  display: flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 600; color: var(--ink);
}
.ct-head .ico { width: 15px; height: 15px; color: var(--brand-2); }
.ct-head .lbl-tip { margin-left: auto; font-weight: 400; }
.ct-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.ct-chips .chip { height: 22px; }

/* 协办费（合作律师费）提款状态 */
.ct-fee {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: 10px; padding-top: 9px; border-top: 1px dashed var(--line);
  font-size: 12px; color: #6b7789;
}
.ct-fee .btn { margin-left: auto; }

/* 办理进展时间线 */
.prog-list { display: flex; flex-direction: column; gap: 2px; margin-bottom: 12px; }
.prog-item { display: flex; gap: 10px; padding: 6px 0; position: relative; }
.prog-item::before {
  content: ''; position: absolute; left: 3.5px; top: 18px; bottom: -6px;
  width: 1px; background: var(--line);
}
.prog-item:last-child::before { display: none; }
.prog-dot {
  width: 8px; height: 8px; margin-top: 6px; border-radius: 50%;
  background: var(--brand-2); flex: 0 0 auto;
}
.prog-main { flex: 1; min-width: 0; }
.prog-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 11.5px; color: #8a97a9;
}
.prog-head b { color: var(--ink); font-weight: 600; }
.prog-head .icon-btn { margin-left: auto; }
.prog-body { font-size: 12.5px; color: #46536b; line-height: 1.7; margin-top: 2px; white-space: pre-wrap; }

.msg-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.msg {
  max-width: 88%; padding: 9px 12px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px 12px 12px 4px;
}
.msg.mine {
  margin-left: auto; background: var(--brand-soft); border-color: #d6e5f6;
  border-radius: 12px 12px 4px 12px;
}
.msg-head {
  display: flex; align-items: center; gap: 6px;
  font-size: 11.5px; color: var(--ink-3); margin-bottom: 3px;
}
.msg-head b { color: var(--ink-2); font-weight: 600; }
.msg-time { font-size: 10.5px; }
.msg-head .icon-btn { margin-left: auto; }
.msg-body { font-size: 12.5px; color: var(--ink-2); white-space: pre-wrap; word-break: break-word; }
.msg-send { display: flex; gap: 8px; align-items: flex-end; }
.msg-send textarea { flex: 1; resize: none; min-height: 44px; }
.msg-send .btn { flex: none; }
.count {
  display: inline-block; min-width: 17px; height: 17px; padding: 0 5px;
  background: #eef1f5; border-radius: 9px; font-size: 10.5px;
  text-align: center; line-height: 17px; color: var(--ink-3); font-weight: 600;
}

/* ---------- 案例库 ---------- */
.case-lib-card { transition: border-color .15s, box-shadow .15s, transform .15s; }
.case-lib-card:hover { border-color: #c7d7e8; box-shadow: 0 6px 18px rgba(16,40,70,.07); transform: translateY(-1px); }
.case-lib-card .chip[data-action] { cursor: pointer; }
