/* ============================================================
   GINTOL · 内容管理后台 v2（重构版）
   深色侧栏 + 浅色工作区 + 橙色强调，与前台同一套品牌色
   ============================================================ */
:root {
  --o: #ff6a13;
  --o-deep: #f0520a;
  --o-soft: #fff3ea;
  --ink: #1b2437;
  --ink-2: #46536b;
  --muted: #8593a8;
  --line: #e6e9f0;
  --bg: #f4f5f8;
  --card: #ffffff;
  --side: #141a28;
  --side-ink: #c6cddd;
  --side-line: rgba(255, 255, 255, .08);
  --radius: 14px;
  --shadow: 0 10px 30px rgba(23, 32, 51, .07);
  --font: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.modal-open { overflow: hidden; }
h1, h2, h3, h4, p { margin: 0; }
a { color: var(--o-deep); text-decoration: none; }
code { background: #eef0f5; padding: 1px 6px; border-radius: 5px; font-size: 12px; }
b { font-weight: 700; }
small { color: var(--muted); }

/* ---------- 通用按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px; border-radius: 10px; border: 1px solid transparent;
  font: 600 13.5px var(--font); cursor: pointer; white-space: nowrap;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, opacity .15s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.btn-primary { background: linear-gradient(135deg, #ff7a1f, var(--o-deep)); color: #fff; box-shadow: 0 6px 16px rgba(240, 82, 10, .28); }
.btn-primary:hover { box-shadow: 0 8px 20px rgba(240, 82, 10, .36); }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--ink-2); }
.btn-ghost:hover { border-color: #cfd6e2; color: var(--ink); }
.btn-soft { background: var(--o-soft); color: var(--o-deep); }
.btn-soft:hover { background: #ffe8d6; }
.btn-danger { background: #fdecec; color: #d64545; }
.btn-danger:hover { background: #fbdddd; }
.btn-sm { padding: 6px 12px; font-size: 12.5px; border-radius: 8px; }
.btn-block { width: 100%; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line);
  background: #fff; color: var(--ink-2); cursor: pointer; font-size: 14px;
}
.icon-btn:hover { border-color: #cfd6e2; color: var(--ink); }

/* ---------- 登录页 ---------- */
.auth-wrap { min-height: 100vh; display: flex; align-items: stretch; justify-content: center; padding: 40px 20px; }
.auth-stage {
  display: grid; grid-template-columns: 1fr 420px; max-width: 980px; width: 100%;
  border-radius: 22px; overflow: hidden; box-shadow: 0 24px 70px rgba(23, 32, 51, .16);
  background: #fff; min-height: 560px;
}
.auth-side {
  background:
    radial-gradient(120% 90% at 110% -10%, rgba(255, 122, 31, .35), transparent 55%),
    radial-gradient(90% 70% at -10% 110%, rgba(56, 189, 248, .18), transparent 55%),
    var(--side);
  color: #e8ecf5; padding: 44px 40px; display: flex; flex-direction: column;
}
.auth-side-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; }
.auth-side-brand strong { font-size: 20px; letter-spacing: .04em; }
.auth-side h2 { font-size: 26px; font-weight: 800; letter-spacing: -.02em; line-height: 1.35; }
.auth-side p { margin-top: 14px; font-size: 13.5px; line-height: 1.9; color: #aeb8cb; }
.auth-side-list { list-style: none; margin: auto 0 0; padding: 26px 0 0; border-top: 1px solid var(--side-line); }
.auth-side-list li { padding: 7px 0 7px 22px; position: relative; color: #c6cddd; font-size: 13px; }
.auth-side-list li::before {
  content: ""; position: absolute; left: 2px; top: 14px; width: 7px; height: 7px;
  border-radius: 50%; background: var(--o); box-shadow: 0 0 8px rgba(255, 106, 19, .8);
}
.auth-card { padding: 48px 44px; display: flex; flex-direction: column; justify-content: center; }
.auth-card h2 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.auth-desc { color: var(--muted); font-size: 13px; margin: 10px 0 26px; }
.auth-msg { min-height: 20px; font-size: 12.5px; color: #d64545; margin: 4px 0 10px; }
.auth-foot { color: var(--muted); font-size: 12px; line-height: 1.8; margin-top: 22px; border-top: 1px dashed var(--line); padding-top: 16px; }
.auth-logo {
  width: 40px; height: 40px; border-radius: 12px; flex: none;
  background: linear-gradient(135deg, #ff7a1f, var(--o-deep));
  color: #fff; font: 800 19px var(--font);
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 14px rgba(240, 82, 10, .3);
}

/* ---------- 表单 ---------- */
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 6px; }
.inp {
  width: 100%; padding: 10px 13px; border-radius: 10px; border: 1.5px solid var(--line);
  background: #fff; color: var(--ink); font: 400 13.5px var(--font); outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.inp:focus { border-color: var(--o); box-shadow: 0 0 0 3px rgba(255, 106, 19, .14); }
textarea.inp { resize: vertical; min-height: 64px; line-height: 1.7; }
select.inp { cursor: pointer; }
.hint { font-size: 11.5px; color: var(--muted); margin-top: 5px; line-height: 1.7; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0 16px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.form-section { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 6px; margin-bottom: 16px; background: #fdfdfe; }
.form-section h4 { font-size: 13.5px; font-weight: 700; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); color: var(--ink); }
.form-section h4::before { content: ""; display: inline-block; width: 4px; height: 13px; border-radius: 2px; background: var(--o); margin-right: 8px; vertical-align: -1px; }
.with-tool { position: relative; }

/* ---------- 顶栏 ---------- */
.app-view { min-height: 100vh; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 10px 22px; background: rgba(255, 255, 255, .92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.topbar-brand { display: flex; align-items: center; gap: 10px; }
.topbar-brand .auth-logo { width: 34px; height: 34px; font-size: 16px; border-radius: 10px; }
.topbar-brand strong { display: block; font-size: 14.5px; letter-spacing: .03em; line-height: 1.2; }
.topbar-brand small { display: block; font-size: 10.5px; color: var(--muted); }
.side-toggle { display: none; }
.topbar-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.mode-badge {
  padding: 4px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap;
  background: #ecfdf3; color: #16803c; border: 1px solid #bfe8cf;
}
.mode-badge.local { background: #fff7ed; color: #c2570a; border-color: #fcd9b2; }
.save-state { font-size: 12px; color: var(--muted); white-space: nowrap; }
.save-state.dirty { color: #c2570a; font-weight: 700; }
.me-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 5px;
  border-radius: 999px; border: 1px solid var(--line); background: #fff; cursor: pointer;
}
.me-avatar {
  width: 27px; height: 27px; border-radius: 50%; flex: none;
  background: var(--o-soft); color: var(--o-deep); font: 800 12.5px var(--font);
  display: inline-flex; align-items: center; justify-content: center;
}
.me-txt { text-align: left; line-height: 1.15; }
.me-txt b { display: block; font-size: 12px; }
.me-txt small { display: block; font-size: 10px; }

/* ---------- 主体布局 ---------- */
.shell { flex: 1; display: flex; min-height: 0; }
.sidebar {
  width: 224px; flex: none; background: var(--side); color: var(--side-ink);
  padding: 18px 12px 22px; display: flex; flex-direction: column; gap: 4px;
  position: sticky; top: 55px; height: calc(100vh - 55px); overflow-y: auto;
}
.side-label { font-size: 10.5px; letter-spacing: .18em; color: #6d7a92; padding: 6px 12px 8px; font-weight: 700; }
.nav-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  width: 100%; padding: 9px 13px; border-radius: 10px; border: 0; cursor: pointer;
  background: transparent; color: var(--side-ink); font: 500 13.5px var(--font);
  transition: background .15s, color .15s;
}
.nav-item:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.nav-item.active { background: linear-gradient(135deg, #ff7a1f, var(--o-deep)); color: #fff; font-weight: 700; box-shadow: 0 6px 14px rgba(240, 82, 10, .35); }
.n-count {
  font-size: 10.5px; padding: 1px 7px; border-radius: 999px;
  background: rgba(255, 255, 255, .1); color: inherit; font-weight: 700;
}
.nav-item.active .n-count { background: rgba(255, 255, 255, .25); }
.side-note { margin-top: auto; padding: 14px 12px 0; border-top: 1px solid var(--side-line); font-size: 11.5px; line-height: 1.9; color: #8a95ab; }
.side-note code { background: rgba(255, 255, 255, .08); color: #c6cddd; }
.sidebar-mask { display: none; }
.workspace { flex: 1; min-width: 0; padding: 26px 30px 60px; }
.ws-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.ws-head h1 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.ws-head p { color: var(--muted); font-size: 12.5px; margin-top: 3px; }
.ws-actions { display: flex; gap: 9px; }
.panel { max-width: 1080px; }
.panel-tip { background: var(--o-soft); border: 1px solid #fcd9b2; color: #9a4a0e; padding: 10px 14px; border-radius: 10px; font-size: 12.5px; margin-bottom: 14px; }

/* ---------- 卡片 / 概览 ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 16px; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h3 { font-size: 15.5px; font-weight: 800; }
.card-head p { font-size: 12px; color: var(--muted); margin-top: 2px; }
.card-box { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: #fdfdfe; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-bottom: 16px; }
.stat-box {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px 18px; position: relative; overflow: hidden;
}
.stat-box::after { content: ""; position: absolute; right: -18px; top: -18px; width: 64px; height: 64px; border-radius: 50%; background: var(--o-soft); opacity: .7; }
.s-num { font-size: 24px; font-weight: 800; letter-spacing: -.02em; position: relative; z-index: 1; }
.s-label { font-size: 11.5px; color: var(--muted); position: relative; z-index: 1; }
.quick-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.quick {
  display: flex; align-items: center; gap: 12px; text-align: left;
  padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line);
  background: #fff; cursor: pointer; transition: border-color .15s, box-shadow .15s;
}
.quick:hover { border-color: #f3b47d; box-shadow: 0 8px 18px rgba(240, 82, 10, .12); }
.q-ico {
  width: 36px; height: 36px; border-radius: 10px; flex: none;
  background: var(--o-soft); color: var(--o-deep);
  display: inline-flex; align-items: center; justify-content: center; font-size: 16px; font-weight: 800;
}
.quick b { display: block; font-size: 13px; }
.quick small { display: block; font-size: 11px; }
.mini-list { display: flex; flex-direction: column; gap: 8px; }
.mini-row { display: flex; align-items: center; gap: 10px; }
.mini-row .inp { flex: 1; }
.hs-row { display: flex; align-items: center; gap: 10px; }

/* ---------- 工具条 / 表格 ---------- */
.toolbar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 12px; }
.toolbar .inp { width: auto; min-width: 150px; flex: 1; max-width: 320px; }
.table-wrap { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  text-align: left; padding: 11px 14px; font-size: 11.5px; font-weight: 700; color: var(--muted);
  border-bottom: 1px solid var(--line); background: #fafbfc; white-space: nowrap;
}
td { padding: 11px 14px; border-bottom: 1px solid #f0f2f6; vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tr:hover td { background: #fafbfd; }
.empty-row { text-align: center; color: var(--muted); padding: 26px !important; }
.t-ico {
  width: 40px; height: 40px; border-radius: 10px; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 14px;
  background: linear-gradient(140deg, #FF9A4D, #F0520A);
}
.t-ico.tut { background: linear-gradient(140deg, #38bdf8, #2563eb); }
.t-name { display: flex; align-items: center; gap: 11px; min-width: 0; }
.t-name > div { min-width: 0; }
.t-sub { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.t-title { font-weight: 700; }
.t-desc { font-size: 11.5px; color: var(--muted); }
.t-actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.pill {
  display: inline-flex; align-items: center; padding: 2.5px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 700; background: #eef0f5; color: var(--ink-2); white-space: nowrap;
}
.pill.green { background: #ecfdf3; color: #16803c; }
.pill.blue { background: #eaf3ff; color: #1d5fd0; }
.pill.orange { background: var(--o-soft); color: #c2570a; }
.pill.red { background: #fdecec; color: #d64545; }
.pill.gray { background: #eef0f5; color: var(--muted); }

/* ---------- 软件表格专属 ---------- */
.app-ic {
  width: 40px; height: 40px; border-radius: 10px; flex: none; overflow: hidden;
  background: linear-gradient(135deg, #ff8a3d, var(--o-deep));
  color: #fff; font: 800 16px var(--font);
  display: inline-flex; align-items: center; justify-content: center;
}
.app-ic.has-logo { background: #fff; border: 1px solid var(--line); }
.app-ic .ic-img { width: 100%; height: 100%; object-fit: contain; }
.app-ic .ic-txt { line-height: 1; }
.app-ic.fit-contain .ic-img { object-fit: contain; }
.ic-txt { font-size: 15px; }
.news-ico { width: 44px; height: 44px; }
.bname { min-width: 0; }
.app-table th:first-child, .app-table td:first-child { width: 34px; text-align: center; }
.app-check { width: 15px; height: 15px; accent-color: var(--o); cursor: pointer; }
.order-cell { white-space: nowrap; }
.order-btns { display: inline-flex; gap: 4px; margin-right: 8px; vertical-align: middle; }
.order-btns button {
  width: 24px; height: 24px; border-radius: 7px; border: 1px solid var(--line);
  background: #fff; cursor: pointer; color: var(--ink-2); font-size: 11px; line-height: 1;
}
.order-btns button:hover { border-color: var(--o); color: var(--o-deep); }
.order-no { color: var(--muted); font-size: 12px; }
.batch-bar { display: flex; align-items: center; gap: 10px; padding: 9px 14px; background: var(--o-soft); border: 1px solid #fcd9b2; border-radius: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.batch-count { font-size: 12.5px; font-weight: 700; color: #9a4a0e; }
.pkg-state, .lock, .drag { font-size: 11px; color: var(--muted); }
.dl-perm-card { border: 1px dashed #f3b47d; background: #fffaf5; border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; font-size: 12.5px; color: #9a4a0e; }

/* ---------- 提示 ---------- */
.notice { padding: 11px 15px; border-radius: 10px; font-size: 12.5px; line-height: 1.8; margin-bottom: 14px; }
.notice.info { background: #eef4ff; border: 1px solid #cfdefc; color: #2c5bb8; }
.notice.warn { background: #fff7ed; border: 1px solid #fcd9b2; color: #9a4a0e; }
.code-block {
  background: #101522; color: #d7e2f5; border-radius: 10px; padding: 13px 16px;
  font: 12px/1.8 Consolas, Monaco, monospace; overflow-x: auto; white-space: pre;
}
.deploy-steps { display: flex; flex-direction: column; gap: 10px; }
.deploy-step { display: flex; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; }
.check-row { display: flex; align-items: center; gap: 9px; padding: 10px 13px; border-radius: 10px; border: 1px solid var(--line); background: #fff; font-size: 12.5px; }
.check-row.ok { border-color: #bfe8cf; background: #f2fdf6; }
.check-row.no { border-color: #f2c4c4; background: #fff7f7; }
.backup-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 13px; border-bottom: 1px solid #f0f2f6; font-size: 12.5px; flex-wrap: wrap; }
.backup-item:last-child { border-bottom: 0; }

/* ---------- 各类上传/预览选择器 ---------- */
.site-logo-row, .sl-actions, .ip-btns, .step-tools, .ii-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sl-preview, .cp-preview, .ip-preview, .qr-preview {
  border: 1.5px dashed var(--line); border-radius: 12px; background: #fafbfd;
  display: flex; align-items: center; justify-content: center; overflow: hidden; color: var(--muted);
}
.sl-preview { width: 64px; height: 64px; font-size: 20px; font-weight: 800; flex: none; }
.sl-preview img { width: 100%; height: 100%; object-fit: contain; }
.sl-thumb { width: 120px; height: 68px; border-radius: 10px; object-fit: cover; background: #eef0f5; flex: none; }
.cover-picker { display: flex; gap: 14px; align-items: flex-start; }
.cp-preview { width: 220px; height: 124px; flex: none; font-size: 12px; text-align: center; line-height: 1.7; }
.cp-preview img { width: 100%; height: 100%; object-fit: cover; }
.ip-main { flex: 1; min-width: 0; }
.ip-preview { width: 56px; height: 56px; flex: none; }
.ip-preview img { width: 100%; height: 100%; object-fit: contain; }
.icon-picker { display: flex; gap: 14px; align-items: flex-start; }
.intro-list { display: flex; flex-direction: column; gap: 10px; }
.intro-row { display: flex; gap: 12px; align-items: flex-start; border: 1px solid var(--line); border-radius: 12px; padding: 10px; background: #fff; }
.ii-thumb { width: 120px; height: 76px; object-fit: cover; border-radius: 9px; background: #eef0f5; flex: none; }
.ii-fields { flex: 1; min-width: 0; }
.qr-picker { display: flex; gap: 14px; align-items: flex-start; }
.qr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.qr-main { flex: 1; min-width: 0; }
.qr-preview { width: 108px; height: 108px; flex: none; font-size: 11px; }
.qr-preview img { width: 100%; height: 100%; object-fit: contain; }
.color-field { display: flex; align-items: center; gap: 8px; }
.color-field input[type="color"] { width: 40px; height: 32px; border: 1px solid var(--line); border-radius: 8px; padding: 2px; background: #fff; cursor: pointer; }

/* ---------- Markdown 编辑器 ---------- */
.md-editor { border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; }
.md-tools { display: flex; align-items: center; gap: 5px; padding: 8px 10px; background: #fafbfc; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.md-tools button {
  padding: 5px 10px; border-radius: 7px; border: 1px solid transparent; background: transparent;
  cursor: pointer; color: var(--ink-2); font-size: 12px; font-weight: 600;
}
.md-tools button:hover { background: #eef0f5; color: var(--ink); }
.md-input { display: block; width: 100%; border: 0; outline: none; padding: 14px; min-height: 220px; font: 13px/1.85 Consolas, "PingFang SC", monospace; resize: vertical; background: #fff; color: var(--ink); }
.md-preview { padding: 16px 18px; border-top: 1px dashed var(--line); font-size: 13.5px; line-height: 1.9; }
.md-preview img { max-width: 100%; border-radius: 10px; }
.md-preview h1, .md-preview h2, .md-preview h3 { margin: 14px 0 8px; }
.md-preview p { margin: 8px 0; }

/* ---------- 账号 / 权限 ---------- */
.perm-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.sr-head { display: flex; align-items: center; gap: 12px; }
.sr-no { width: 30px; height: 30px; border-radius: 9px; background: var(--o-soft); color: var(--o-deep); font: 800 12px var(--font); display: inline-flex; align-items: center; justify-content: center; flex: none; }

/* ---------- 编辑抽屉（右侧滑出） ---------- */
.drawer-root { position: fixed; inset: 0; z-index: 90; }
.drawer-mask { position: absolute; inset: 0; background: rgba(16, 21, 34, .5); backdrop-filter: blur(2px); opacity: 0; transition: opacity .25s; }
.drawer-panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(620px, 96vw);
  background: #fff; display: flex; flex-direction: column;
  box-shadow: -24px 0 60px rgba(16, 21, 34, .25);
  animation: drawerIn .28s cubic-bezier(.32, .72, .35, 1);
}
@keyframes drawerIn { from { transform: translateX(60px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 18px 22px 14px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { font-size: 17px; font-weight: 800; }
.drawer-head p { font-size: 12px; color: var(--muted); margin-top: 2px; }
.drawer-body { flex: 1; overflow-y: auto; padding: 18px 22px; background: #f8f9fb; }
.drawer-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 22px; border-top: 1px solid var(--line); background: #fff;
}
.drawer-hint { font-size: 11.5px; color: var(--muted); }

/* ---------- 插入弹窗 ---------- */
.modal-root { position: fixed; inset: 0; z-index: 95; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal-mask { position: absolute; inset: 0; background: rgba(16, 21, 34, .5); }
.modal-panel {
  position: relative; width: min(720px, 96vw); max-height: 88vh; display: flex; flex-direction: column;
  background: #fff; border-radius: 18px; box-shadow: 0 30px 80px rgba(16, 21, 34, .35);
  animation: modalIn .22s ease;
}
@keyframes modalIn { from { transform: translateY(14px) scale(.98); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-sm { width: min(520px, 96vw); }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 18px 22px 12px; }
.modal-head h2 { font-size: 16.5px; font-weight: 800; }
.modal-head p { font-size: 12px; color: var(--muted); margin-top: 2px; }
.modal-body { flex: 1; overflow-y: auto; padding: 4px 22px 14px; }
.modal-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 22px; border-top: 1px solid var(--line); }
.modal-hint { font-size: 11.5px; color: var(--muted); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 34px; transform: translate(-50%, 16px);
  background: #1b2437; color: #fff; padding: 11px 20px; border-radius: 12px;
  font-size: 13px; font-weight: 600; box-shadow: 0 14px 34px rgba(16, 21, 34, .35);
  opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 120; max-width: 90vw;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: #b3361f; }

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .side-toggle { display: inline-flex; }
  .sidebar {
    position: fixed; left: 0; top: 0; bottom: 0; height: 100vh; z-index: 80;
    transform: translateX(-100%); transition: transform .28s ease; width: 248px; padding-top: 20px;
  }
  .sidebar.open { transform: none; box-shadow: 24px 0 60px rgba(16, 21, 34, .3); }
  .sidebar-mask { position: fixed; inset: 0; background: rgba(16, 21, 34, .45); z-index: 70; }
  .workspace { padding: 20px 16px 50px; }
  .auth-stage { grid-template-columns: 1fr; }
  .auth-side { display: none; }
}
@media (max-width: 720px) {
  .topbar { padding: 8px 12px; }
  .topbar-actions .btn-ghost { display: none; }
  .drawer-panel { width: 100vw; }
  .row-2, .row-3, .form-grid, .qr-grid { grid-template-columns: 1fr; }
  .cover-picker, .icon-picker, .qr-picker { flex-direction: column; }
  .cp-preview { width: 100%; }
  .ws-head { flex-direction: column; align-items: flex-start; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .drawer-panel, .modal-panel { animation: none; }
}

/* ---------- 维修工单面板 ---------- */
.rp-row{border:1.5px solid #eceef3;border-radius:14px;padding:14px 16px;margin-bottom:12px;background:#fff}
.rp-row-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:10px}
.rp-row-head b{color:#e45400;font-size:15.5px;letter-spacing:.5px}
.rp-row-head small{color:#9aa1ad;font-size:12.5px}
.rp-row-head .t-actions{margin-left:auto;display:flex;gap:8px}
.rp-row-grid{display:grid;grid-template-columns:76px 1fr;gap:8px 12px;align-items:center}
.rp-row-grid span{color:#8b909c;font-size:12.5px}
.rp-row-grid i{font-style:normal;color:#3c4250;font-size:13.5px;line-height:1.6;word-break:break-all}
.rp-row-grid .inp{padding:8px 11px;font-size:13.5px}
#repairSyncText{margin-top:8px;white-space:pre;font-size:13px;line-height:1.6}
