/* ============================================================
   星轨 OA · 设计系统
   主色 #3370FF（飞书蓝），弱化线条、以留白与浅底分隔区块
   ============================================================ */

:root {
  --brand: #3370ff;
  --brand-hover: #245bdb;
  --brand-soft: #eaf1ff;
  --brand-soft-2: #f2f6ff;

  --bg: #f5f6f8;
  --surface: #ffffff;
  --surface-2: #fafbfc;

  --text: #1f2329;
  --text-2: #646a73;
  --text-3: #8f959e;
  --text-4: #b8bcc2;

  --line: #eff0f1;
  --line-strong: #e5e6eb;

  --red: #f54a45;
  --red-soft: #fff1f0;
  --green: #34c724;
  --green-soft: #e8f8e6;
  --orange: #ff8800;
  --orange-soft: #fff5e6;
  --purple: #7b61ff;
  --purple-soft: #f0edff;
  --cyan: #14c0ff;
  --cyan-soft: #e6f7ff;
  --gray-soft: #f2f3f5;

  --r-lg: 14px;
  --r-md: 10px;
  --r-sm: 7px;

  --shadow-1: 0 1px 2px rgba(31, 35, 41, .04);
  --shadow-2: 0 4px 16px rgba(31, 35, 41, .07);
  --shadow-3: 0 12px 42px rgba(31, 35, 41, .14);

  --sidebar-w: 232px;
  --topbar-h: 58px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
               "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button, input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
a { color: var(--brand); text-decoration: none; }
h1, h2, h3, h4, p { margin: 0; }
.num { font-variant-numeric: tabular-nums; }

/* ---------------- 启动占位 ---------------- */
.app-root { min-height: 100vh; }
.boot { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; color: var(--text-3); }
.boot-logo {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--brand), #5b8cff);
  animation: pulse 1.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1);} 50% { opacity: .65; transform: scale(.94);} }

/* ============================================================
   登录页
   ============================================================ */
.login-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  background:
    radial-gradient(900px 480px at 12% -8%, #e8efff 0%, rgba(232,239,255,0) 62%),
    radial-gradient(760px 420px at 104% 108%, #eef1ff 0%, rgba(238,241,255,0) 60%),
    var(--bg);
}

.login-card {
  width: 900px;
  max-width: 100%;
  min-height: 528px;
  display: grid;
  grid-template-columns: 388px 1fr;
  background: var(--surface);
  border-radius: 20px;
  box-shadow: var(--shadow-3);
  overflow: hidden;
}

/* 左侧品牌区 */
.login-brand {
  position: relative;
  padding: 44px 40px;
  color: #fff;
  background: linear-gradient(158deg, #2b62e8 0%, #3370ff 46%, #5a8bff 100%);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.login-brand::before,
.login-brand::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
}
.login-brand::before { width: 320px; height: 320px; right: -140px; top: -110px; }
.login-brand::after  { width: 240px; height: 240px; left: -110px; bottom: -120px; background: rgba(255,255,255,.07); }

.lb-mark {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 40px;
}
.lb-mark-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: rgba(255,255,255,.2);
  display: grid; place-items: center;
  font-weight: 700; font-size: 15px; letter-spacing: .5px;
  backdrop-filter: blur(4px);
}
.lb-mark-text { font-size: 15px; font-weight: 600; letter-spacing: .3px; }

.lb-title { position: relative; font-size: 27px; font-weight: 600; line-height: 1.36; letter-spacing: .4px; }
.lb-desc { position: relative; margin-top: 14px; font-size: 13.5px; line-height: 1.75; color: rgba(255,255,255,.78); }

.lb-points { position: relative; margin-top: auto; padding-top: 36px; display: flex; flex-direction: column; gap: 12px; }
.lb-point { display: flex; align-items: center; gap: 10px; font-size: 13px; color: rgba(255,255,255,.9); }
.lb-dot { width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.75); flex: none; }

/* 右侧登录区 */
.login-form {
  padding: 46px 44px 40px;
  display: flex;
  flex-direction: column;
}
.lf-head { margin-bottom: 22px; }
.lf-title { font-size: 20px; font-weight: 600; letter-spacing: .2px; }
.lf-sub { margin-top: 7px; font-size: 13px; color: var(--text-3); }

.qr-wrap {
  width: 268px;
  min-height: 268px;
  border-radius: var(--r-md);
  background: var(--surface-2);
  display: grid;
  place-items: center;
  padding: 14px;
  position: relative;
  overflow: hidden;
}
.qr-wrap.is-ready { background: #fff; }
#qr-container { width: 250px; height: 250px; display: flex; align-items: center; justify-content: center; }
#qr-container iframe, #qr-container canvas, #qr-container img { max-width: 250px; max-height: 250px; }

.qr-placeholder {
  text-align: center;
  color: var(--text-3);
  font-size: 13px;
  line-height: 1.8;
  padding: 0 12px;
}
.qr-placeholder .qr-ico {
  width: 46px; height: 46px; margin: 0 auto 12px;
  border-radius: 12px; background: var(--brand-soft);
  display: grid; place-items: center; color: var(--brand); font-size: 21px;
}
.qr-loading { display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--text-3); font-size: 13px; }
.spinner {
  width: 22px; height: 22px; border-radius: 50%;
  border: 2.4px solid var(--brand-soft);
  border-top-color: var(--brand);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.qr-tip { margin-top: 16px; display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--text-3); }
.qr-tip svg { flex: none; }

.login-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 22px 0 16px; color: var(--text-4); font-size: 12px;
}
.login-divider::before, .login-divider::after {
  content: ""; height: 1px; flex: 1; background: var(--line);
}

.pwd-toggle {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--brand); font-size: 13px; align-self: flex-start;
}
.pwd-toggle:hover { color: var(--brand-hover); }

.pwd-form { display: flex; flex-direction: column; gap: 12px; margin-top: 4px; }

.lf-foot { margin-top: auto; padding-top: 26px; font-size: 12px; color: var(--text-4); line-height: 1.7; }

/* ============================================================
   表单控件
   ============================================================ */
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label { font-size: 12.5px; color: var(--text-2); font-weight: 500; }
.field .hint { font-size: 11.5px; color: var(--text-4); }

.input, .select, .textarea {
  width: 100%;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  background: #fff;
  outline: none;
  transition: border-color .16s, box-shadow .16s, background .16s;
}
.textarea { height: auto; min-height: 84px; padding: 10px 12px; resize: vertical; line-height: 1.65; }
.input:hover, .select:hover, .textarea:hover { border-color: #d0d3d9; }
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(51, 112, 255, .12);
}
.input::placeholder, .textarea::placeholder { color: var(--text-4); }
.select { appearance: none; padding-right: 32px; cursor: pointer;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 4.5L6 8l3.5-3.5' stroke='%238f959e' stroke-width='1.4' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 16px;
  border: 0; border-radius: var(--r-sm);
  background: var(--brand); color: #fff;
  font-size: 13.5px; font-weight: 500; cursor: pointer;
  transition: background .16s, transform .06s, box-shadow .16s;
  white-space: nowrap;
}
.btn:hover { background: var(--brand-hover); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn-block { width: 100%; }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--gray-soft); color: var(--text); }
.btn-soft { background: var(--brand-soft); color: var(--brand); }
.btn-soft:hover { background: #dde8ff; }
.btn-danger { background: var(--red-soft); color: var(--red); }
.btn-danger:hover { background: #ffe3e1; }
.btn-sm { height: 30px; padding: 0 11px; font-size: 12.5px; border-radius: 6px; }
.btn-xs { height: 26px; padding: 0 9px; font-size: 12px; border-radius: 5px; }

/* ============================================================
   应用框架
   ============================================================ */
.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  min-height: 100vh;
}

/* 侧边栏 */
.sidebar {
  background: var(--surface);
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 20;
}
.sb-brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 0; margin-bottom: 22px; }
.sb-logo {
  width: 32px; height: 32px; border-radius: 9px; flex: none;
  background: linear-gradient(135deg, #2b62e8, #5a8bff);
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 13px;
}
.sb-name { font-size: 14px; font-weight: 600; letter-spacing: .2px; line-height: 1.2; }
.sb-sub { font-size: 11px; color: var(--text-4); margin-top: 2px; }

.sb-group-label {
  font-size: 11px; color: var(--text-4);
  padding: 0 10px; margin: 14px 0 6px; letter-spacing: .6px;
}

.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-item {
  display: flex; align-items: center; gap: 10px;
  height: 38px; padding: 0 10px;
  border-radius: var(--r-sm);
  color: var(--text-2); cursor: pointer;
  transition: background .14s, color .14s;
  user-select: none;
}
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item.active { background: var(--brand-soft); color: var(--brand); font-weight: 500; }
.nav-item .ico { width: 17px; height: 17px; flex: none; opacity: .85; }
.nav-item.active .ico { opacity: 1; }
.nav-count {
  margin-left: auto; font-size: 11px; color: var(--text-4);
  background: var(--gray-soft); padding: 1px 6px; border-radius: 9px;
}
.nav-item.active .nav-count { background: rgba(51,112,255,.14); color: var(--brand); }

.sb-user {
  margin-top: auto;
  display: flex; align-items: center; gap: 10px;
  padding: 10px; border-radius: var(--r-md);
  background: var(--surface-2);
  cursor: pointer;
}
.sb-user:hover { background: #f4f5f7; }
.avatar {
  width: 32px; height: 32px; border-radius: 50%; flex: none;
  background: var(--brand-soft); color: var(--brand);
  display: grid; place-items: center; font-size: 12.5px; font-weight: 600;
  overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-sm { width: 26px; height: 26px; font-size: 11px; }
.sb-user-meta { min-width: 0; }
.sb-user-name { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-user-role { font-size: 11px; color: var(--text-3); }

/* 主区 */
.main { display: flex; flex-direction: column; min-width: 0; }

.topbar {
  height: var(--topbar-h);
  display: flex; align-items: center; gap: 16px;
  padding: 0 26px;
  background: rgba(245, 246, 248, .82);
  backdrop-filter: blur(10px);
  position: sticky; top: 0; z-index: 15;
}
.tb-title { font-size: 16px; font-weight: 600; letter-spacing: .2px; }
.tb-sub { font-size: 12.5px; color: var(--text-3); margin-left: 2px; }
.tb-spacer { flex: 1; }

.search-box {
  position: relative; width: 260px;
}
.search-box svg { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-4); }
.search-box .input { height: 34px; padding-left: 33px; background: #fff; border-color: transparent; box-shadow: var(--shadow-1); }
.search-box .input:focus { border-color: var(--brand); }

.content { padding: 6px 26px 40px; }

/* ============================================================
   通用面板与卡片
   ============================================================ */
.panel {
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1);
  padding: 20px;
}
.panel-head { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.panel-title { font-size: 14.5px; font-weight: 600; }
.panel-sub { font-size: 12px; color: var(--text-3); }
.panel-actions { margin-left: auto; display: flex; gap: 8px; }

.grid { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-main { grid-template-columns: minmax(0, 1.62fr) minmax(0, 1fr); }

.metric {
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1);
  padding: 18px 20px;
  display: flex; flex-direction: column; gap: 4px;
  position: relative;
  overflow: hidden;
}
.metric-label { font-size: 12.5px; color: var(--text-3); }
.metric-value { font-size: 27px; font-weight: 600; letter-spacing: -.4px; line-height: 1.18; }
.metric-foot { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.metric-accent {
  position: absolute; right: -18px; top: -18px;
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--brand-soft); opacity: .7;
}
.metric.is-warn .metric-accent { background: var(--orange-soft); }
.metric.is-danger .metric-accent { background: var(--red-soft); }
.metric.is-success .metric-accent { background: var(--green-soft); }
.metric-value small { font-size: 13px; font-weight: 500; color: var(--text-3); margin-left: 3px; }

/* 进度条 */
.bar { height: 6px; border-radius: 4px; background: var(--gray-soft); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 4px; background: var(--brand); transition: width .4s ease; }
.bar.is-green > i { background: var(--green); }
.bar.is-orange > i { background: var(--orange); }
.bar.is-red > i { background: var(--red); }

/* 状态标签 */
.tag {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 8px; border-radius: 5px;
  font-size: 12px; font-weight: 500; white-space: nowrap;
  background: var(--gray-soft); color: var(--text-2);
}
.tag::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .9; }
.tag.s-待排期 { background: var(--gray-soft); color: #6b7280; }
.tag.s-拍摄中 { background: var(--cyan-soft); color: #0b93c7; }
.tag.s-剪辑中 { background: var(--purple-soft); color: #6750e0; }
.tag.s-待审核 { background: var(--orange-soft); color: #c96a00; }
.tag.s-已交付 { background: var(--green-soft); color: #1e9c12; }
.tag.s-已归档 { background: #eceef0; color: #7a8087; }
.tag.plain::before { display: none; }

.prio { font-size: 12px; font-weight: 500; display: inline-flex; align-items: center; gap: 5px; }
.prio::before { content: ""; width: 6px; height: 6px; border-radius: 2px; }
.prio.p-紧急 { color: var(--red); } .prio.p-紧急::before { background: var(--red); }
.prio.p-高 { color: var(--orange); } .prio.p-高::before { background: var(--orange); }
.prio.p-中 { color: var(--brand); } .prio.p-中::before { background: var(--brand); }
.prio.p-低 { color: var(--text-3); } .prio.p-低::before { background: var(--text-4); }

/* ============================================================
   表格
   ============================================================ */
.table-wrap { background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; }
table.tb { width: 100%; border-collapse: collapse; }
table.tb thead th {
  text-align: left; font-size: 12px; font-weight: 500; color: var(--text-3);
  padding: 11px 14px; background: var(--surface-2); white-space: nowrap;
}
table.tb tbody td { padding: 13px 14px; font-size: 13px; vertical-align: middle; }
table.tb tbody tr { transition: background .13s; cursor: pointer; }
table.tb tbody tr:hover { background: var(--brand-soft-2); }
table.tb tbody tr:not(:last-child) td { box-shadow: inset 0 -1px 0 var(--line); }
.tb-title-cell { font-weight: 500; }
.tb-code { font-size: 11.5px; color: var(--text-4); font-variant-numeric: tabular-nums; margin-top: 2px; }
.tb-owner { display: flex; align-items: center; gap: 8px; }
.tb-actions { display: flex; gap: 6px; justify-content: flex-end; opacity: .55; transition: opacity .14s; }
table.tb tbody tr:hover .tb-actions { opacity: 1; }
.tb-empty { padding: 54px 20px; text-align: center; color: var(--text-3); font-size: 13px; }
.overdue-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); margin-right: 5px; vertical-align: 1px; }

/* 工具栏 */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.toolbar .grow { flex: 1; }
.seg {
  display: inline-flex; background: var(--surface); border-radius: var(--r-sm);
  padding: 3px; box-shadow: var(--shadow-1);
}
.seg button {
  border: 0; background: transparent; height: 28px; padding: 0 13px;
  border-radius: 5px; font-size: 12.5px; color: var(--text-2); cursor: pointer;
}
.seg button.on { background: var(--brand-soft); color: var(--brand); font-weight: 500; }
.filter-select { height: 32px; border-radius: var(--r-sm); border: 1px solid transparent; background: #fff; padding: 0 30px 0 11px; font-size: 12.5px; color: var(--text-2); box-shadow: var(--shadow-1); cursor: pointer; appearance: none;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 4.5L6 8l3.5-3.5' stroke='%238f959e' stroke-width='1.4' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; }
.filter-select:focus { outline: none; border-color: var(--brand); }

/* ============================================================
   看板
   ============================================================ */
.kanban { display: grid; grid-template-columns: repeat(6, minmax(212px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.kb-col { background: var(--surface-2); border-radius: var(--r-md); padding: 10px; min-height: 200px; }
.kb-col-head { display: flex; align-items: center; gap: 7px; padding: 2px 4px 10px; }
.kb-col-name { font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.kb-col-count { font-size: 11px; color: var(--text-3); background: #fff; padding: 1px 6px; border-radius: 8px; }
.kb-card {
  background: #fff; border-radius: var(--r-sm); padding: 11px 12px;
  box-shadow: var(--shadow-1); margin-bottom: 8px; cursor: pointer;
  transition: box-shadow .15s, transform .1s;
}
.kb-card:hover { box-shadow: var(--shadow-2); transform: translateY(-1px); }
.kb-card-title { font-size: 13px; font-weight: 500; line-height: 1.45; }
.kb-card-meta { display: flex; align-items: center; gap: 8px; margin-top: 9px; }
.kb-card-code { font-size: 11px; color: var(--text-4); font-variant-numeric: tabular-nums; }
.kb-card .bar { margin-top: 9px; height: 4px; }
.kb-drop-hint { font-size: 12px; color: var(--text-4); text-align: center; padding: 18px 0; }

/* ============================================================
   抽屉 / 弹窗
   ============================================================ */
.drawer-mask, .modal-mask {
  position: fixed; inset: 0; background: rgba(31, 35, 41, .42);
  z-index: 100; display: flex;
  animation: fade .18s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.drawer-mask { justify-content: flex-end; }
.drawer {
  width: 590px; max-width: 96vw; height: 100%;
  background: var(--surface); display: flex; flex-direction: column;
  box-shadow: -12px 0 42px rgba(31,35,41,.16);
  animation: slideIn .24s cubic-bezier(.2,.8,.3,1);
}
@keyframes slideIn { from { transform: translateX(40px); opacity: .6; } to { transform: none; opacity: 1; } }
.drawer-head {
  padding: 20px 24px 16px; display: flex; align-items: flex-start; gap: 12px;
}
.drawer-title { font-size: 17px; font-weight: 600; line-height: 1.4; }
.drawer-sub { font-size: 12.5px; color: var(--text-3); margin-top: 4px; }
.drawer-close, .modal-close {
  margin-left: auto; width: 30px; height: 30px; border-radius: 7px;
  border: 0; background: transparent; cursor: pointer; color: var(--text-3);
  display: grid; place-items: center; flex: none;
}
.drawer-close:hover, .modal-close:hover { background: var(--gray-soft); color: var(--text); }
.drawer-body { flex: 1; overflow-y: auto; padding: 0 24px 24px; }
.drawer-foot {
  padding: 14px 24px; display: flex; gap: 10px; justify-content: flex-end;
  background: var(--surface-2);
}

.modal-mask { align-items: center; justify-content: center; padding: 20px; }
.modal {
  width: 468px; max-width: 100%; background: var(--surface);
  border-radius: var(--r-lg); box-shadow: var(--shadow-3);
  animation: pop .2s cubic-bezier(.2,.8,.3,1);
  max-height: calc(100vh - 40px); display: flex; flex-direction: column;
}
@keyframes pop { from { transform: scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-head { padding: 22px 24px 0; display: flex; align-items: flex-start; gap: 12px; }
.modal-icon {
  width: 40px; height: 40px; border-radius: 11px; flex: none;
  display: grid; place-items: center; font-size: 19px;
  background: var(--orange-soft); color: #c96a00;
}
.modal-icon.is-info { background: var(--brand-soft); color: var(--brand); }
.modal-icon.is-danger { background: var(--red-soft); color: var(--red); }
.modal-title { font-size: 16.5px; font-weight: 600; }
.modal-desc { font-size: 13px; color: var(--text-2); line-height: 1.75; margin-top: 8px; }
.modal-body { padding: 16px 24px 4px; overflow-y: auto; }
.modal-foot { padding: 18px 24px 22px; display: flex; gap: 10px; justify-content: flex-end; }

.notice {
  border-radius: var(--r-md); padding: 12px 14px; font-size: 12.5px; line-height: 1.7;
  background: var(--orange-soft); color: #8a4b00;
}
.notice.is-info { background: var(--brand-soft); color: #1c47b5; }
.notice ul { margin: 6px 0 0; padding-left: 17px; }
.notice li { margin-bottom: 2px; }

/* 描述列表 */
.dl { display: grid; grid-template-columns: 92px 1fr; gap: 11px 14px; font-size: 13px; }
.dl dt { color: var(--text-3); font-size: 12.5px; }
.dl dd { margin: 0; color: var(--text); word-break: break-word; }

.section-title {
  font-size: 13px; font-weight: 600; color: var(--text-2);
  margin: 22px 0 12px; display: flex; align-items: center; gap: 8px;
}
.section-title:first-child { margin-top: 4px; }
.section-title .count { font-size: 11.5px; color: var(--text-4); font-weight: 400; }

/* 时间线 */
.timeline { display: flex; flex-direction: column; gap: 0; }
.tl-item { display: flex; gap: 12px; padding-bottom: 16px; position: relative; }
.tl-item:not(:last-child)::before {
  content: ""; position: absolute; left: 4px; top: 15px; bottom: 0; width: 1px; background: var(--line);
}
.tl-dot { width: 9px; height: 9px; border-radius: 50%; background: #fff; box-shadow: inset 0 0 0 2px var(--brand); margin-top: 5px; flex: none; }
.tl-content { min-width: 0; }
.tl-text { font-size: 13px; line-height: 1.6; }
.tl-meta { font-size: 11.5px; color: var(--text-4); margin-top: 3px; }

/* 动态列表 */
.feed { display: flex; flex-direction: column; }
.feed-item { display: flex; gap: 10px; padding: 11px 0; }
.feed-item:not(:last-child) { box-shadow: inset 0 -1px 0 var(--line); }
.feed-text { font-size: 12.8px; line-height: 1.6; min-width: 0; }
.feed-text b { font-weight: 500; }
.feed-meta { font-size: 11.5px; color: var(--text-4); margin-top: 2px; }

/* 图表：横向条 */
.hbars { display: flex; flex-direction: column; gap: 13px; }
.hbar-row { display: grid; grid-template-columns: 82px 1fr 44px; align-items: center; gap: 10px; }
.hbar-label { font-size: 12.5px; color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar-track { height: 8px; background: var(--gray-soft); border-radius: 4px; overflow: hidden; }
.hbar-fill { height: 100%; border-radius: 4px; background: var(--brand); transition: width .5s cubic-bezier(.2,.8,.3,1); }
.hbar-val { font-size: 12px; color: var(--text-3); text-align: right; font-variant-numeric: tabular-nums; }

/* 负载卡 */
.load-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; }
.load-row:not(:last-child) { box-shadow: inset 0 -1px 0 var(--line); }
.load-name { font-size: 13px; }
.load-bar { flex: 1; }
.load-num { font-size: 12px; color: var(--text-3); width: 52px; text-align: right; font-variant-numeric: tabular-nums; }

/* 设置页 */
.settings-grid { display: grid; grid-template-columns: 176px 1fr; gap: 20px; align-items: start; }
.set-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 74px; }
.set-nav-item {
  height: 36px; display: flex; align-items: center; padding: 0 12px;
  border-radius: var(--r-sm); font-size: 13px; color: var(--text-2); cursor: pointer;
}
.set-nav-item:hover { background: var(--surface-2); }
.set-nav-item.on { background: var(--brand-soft); color: var(--brand); font-weight: 500; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span-2 { grid-column: span 2; }
.switch { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; }
.switch input { display: none; }
.switch .track {
  width: 38px; height: 21px; border-radius: 11px; background: #d5d7db; position: relative; transition: background .2s;
}
.switch .track::after {
  content: ""; position: absolute; width: 17px; height: 17px; border-radius: 50%; background: #fff;
  top: 2px; left: 2px; transition: transform .2s; box-shadow: 0 1px 2px rgba(0,0,0,.16);
}
.switch input:checked + .track { background: var(--brand); }
.switch input:checked + .track::after { transform: translateX(17px); }
.switch-label { font-size: 13px; color: var(--text); }

.dict-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 30px; padding: 0 10px; border-radius: 15px;
  background: var(--brand-soft); color: var(--brand); font-size: 12.5px;
}
.chip button { border: 0; background: transparent; cursor: pointer; color: inherit; opacity: .6; font-size: 14px; line-height: 1; padding: 0; }
.chip button:hover { opacity: 1; }

/* Toast */
.toast-root {
  position: fixed; top: 22px; left: 50%; transform: translateX(-50%);
  z-index: 300; display: flex; flex-direction: column; gap: 8px; align-items: center;
  pointer-events: none;
}
.toast {
  background: #1f2329; color: #fff; font-size: 13px;
  padding: 10px 16px; border-radius: 8px; box-shadow: var(--shadow-3);
  animation: toastIn .22s cubic-bezier(.2,.8,.3,1);
  max-width: 420px;
}
.toast.is-error { background: #c9352f; }
.toast.is-success { background: #14883f; }
@keyframes toastIn { from { transform: translateY(-10px); opacity: 0; } to { transform: none; opacity: 1; } }

/* 空状态 */
.empty { text-align: center; padding: 48px 20px; color: var(--text-3); }
.empty .em-ico { width: 52px; height: 52px; border-radius: 14px; background: var(--surface-2); display: grid; place-items: center; margin: 0 auto 14px; color: var(--text-4); font-size: 22px; }
.empty p { font-size: 13px; }
.empty .btn { margin-top: 14px; }

/* 响应式 */
@media (max-width: 1180px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-main { grid-template-columns: 1fr; }
  .kanban { grid-template-columns: repeat(3, minmax(220px, 1fr)); }
}
@media (max-width: 900px) {
  :root { --sidebar-w: 68px; }
  .sb-name, .sb-sub, .sb-user-meta, .nav-item span, .nav-count, .sb-group-label { display: none; }
  .nav-item { justify-content: center; padding: 0; }
  .sb-user { justify-content: center; }
  .login-card { grid-template-columns: 1fr; }
  .login-brand { display: none; }
  .login-form { padding: 36px 28px; }
  .grid-3, .grid-2, .form-grid { grid-template-columns: 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
  .set-nav { flex-direction: row; overflow-x: auto; position: static; }
  .content { padding: 6px 16px 32px; }
  .topbar { padding: 0 16px; }
  .search-box { display: none; }
}
