/* ============================================================
   多平台女装退货质检后台 · PC 端设计系统
   还原规格：白底 + 企业绿 #07C160 + 卡片式布局 + 细边框
   ============================================================ */
:root {
  --green: #07C160;
  --green-hover: #06AD56;
  --green-active: #059648;
  --green-light: #E9F9F0;
  --green-border: #B8EBCC;
  --red: #F54A45;
  --red-light: #FEF0EF;
  --orange: #FF8F1F;
  --orange-light: #FFF5E8;
  --blue: #337DFF;
  --blue-light: #EBF3FF;
  --gray-tag: #F2F3F5;
  --text-1: #1F2329;
  --text-2: #646A73;
  --text-3: #8F959E;
  --border: #E5E7EB;
  --border-light: #EEF0F3;
  --bg-page: #F5F6F8;
  --bg-hover: #F7F8FA;
  --radius: 10px;
  --shadow-card: 0 1px 2px rgba(31, 35, 41, 0.04);
  --shadow-modal: 0 8px 32px rgba(31, 35, 41, 0.16);
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", "Microsoft YaHei", "Segoe UI", sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-1);
  background: var(--bg-page);
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--green-light); }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 14px; color: var(--text-1); }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 1px; border-radius: 4px; }
svg { display: block; }

/* ---------- 布局骨架 ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: 232px; position: fixed; top: 0; bottom: 0; left: 0; z-index: 50;
  background: #fff; border-right: 1px solid var(--border-light);
  display: flex; flex-direction: column;
}
.sidebar-logo {
  display: flex; align-items: center; gap: 10px;
  padding: 18px 16px 16px; border-bottom: 1px solid var(--border-light);
}
.sidebar-logo .logo-mark {
  width: 36px; height: 36px; border-radius: 9px; flex: none;
  background: linear-gradient(135deg, #07C160, #00A94F);
  display: flex; align-items: center; justify-content: center; color: #fff;
}
.sidebar-logo .logo-name { font-size: 15px; font-weight: 600; line-height: 1.25; }
.sidebar-logo .logo-sub { font-size: 11px; color: var(--text-3); line-height: 1.3; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 12px 10px 24px; }
.nav-group { margin-bottom: 18px; }
.nav-group-title {
  font-size: 11px; color: var(--text-3); padding: 0 10px 8px;
  letter-spacing: 0.05em;
}
.nav-item {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 9px 10px; border-radius: 8px; margin-bottom: 2px;
  font-size: 13.5px; color: var(--text-1); text-align: left;
  transition: background 0.15s, color 0.15s;
}
.nav-item svg { color: var(--text-3); flex: none; transition: color 0.15s; }
.nav-item:hover { background: var(--bg-hover); }
.nav-item.active { background: var(--green-light); color: var(--green-active); font-weight: 500; }
.nav-item.active svg { color: var(--green); }
.nav-item .nav-badge {
  margin-left: auto; font-size: 11px; color: #fff; background: var(--red);
  border-radius: 9px; padding: 1px 6px; line-height: 1.4;
}
.sidebar-foot { padding: 12px 16px; border-top: 1px solid var(--border-light); font-size: 11px; color: var(--text-3); line-height: 1.6; }

.main { flex: 1; margin-left: 232px; min-width: 0; }
.page { padding: 20px 28px 48px; max-width: 1480px; }
.page-enter { animation: pageIn 0.28s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes pageIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- 页头 / 面包屑 ---------- */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-3); margin-bottom: 10px; }
.breadcrumb .sep { color: #C0C4CC; }
.breadcrumb .current { color: var(--text-2); }
.page-title { font-size: 20px; font-weight: 600; display: flex; align-items: center; gap: 9px; }
.page-title .title-icon {
  width: 30px; height: 30px; border-radius: 8px; background: var(--green);
  color: #fff; display: inline-flex; align-items: center; justify-content: center; flex: none;
}
.page-desc { font-size: 13px; color: var(--text-3); margin-top: 6px; }
.page-actions { display: flex; align-items: center; gap: 10px; flex: none; }

/* ---------- 卡片 ---------- */
.card { background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius); box-shadow: var(--shadow-card); }
.card-pad { padding: 18px 20px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--border-light); }
.card-title { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.card-title .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); flex: none; }
.card-title .sub { font-size: 12px; color: var(--text-3); font-weight: 400; }
.card-extra { font-size: 12.5px; color: var(--text-2); display: flex; align-items: center; gap: 8px; }
.card-link { font-size: 12.5px; color: var(--green); display: inline-flex; align-items: center; gap: 3px; }
.card-link:hover { text-decoration: underline; }

.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: 1fr 1fr; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-stats { grid-template-columns: repeat(4, 1fr); }
.grid-report { grid-template-columns: 1fr 1fr; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 34px; padding: 0 16px; border-radius: 7px; font-size: 13.5px;
  border: 1px solid transparent; transition: all 0.15s; white-space: nowrap;
  user-select: none;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-hover); }
.btn-outline { background: #fff; border-color: var(--border); color: var(--text-1); }
.btn-outline:hover { border-color: var(--green); color: var(--green); }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--bg-hover); color: var(--text-1); }
.btn-danger-soft { background: var(--red-light); color: var(--red); }
.btn-danger-soft:hover { background: #FDE4E2; }
.btn-sm { height: 28px; padding: 0 10px; font-size: 12.5px; border-radius: 6px; }
.btn-lg { height: 42px; padding: 0 22px; font-size: 14.5px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.55; pointer-events: none; }
.btn .spin { animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 表单 ---------- */
.input, .select, .textarea {
  width: 100%; height: 36px; padding: 0 12px; border-radius: 7px;
  border: 1px solid var(--border); background: #fff; transition: border-color 0.15s, box-shadow 0.15s;
}
.textarea { height: auto; padding: 9px 12px; resize: vertical; line-height: 1.6; }
.input::placeholder, .textarea::placeholder { color: #B4B8BF; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(7, 193, 96, 0.12); outline: none; }
.select { 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='%238F959E' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; padding-right: 30px; cursor: pointer; }
.field-label { font-size: 13px; color: var(--text-2); margin-bottom: 6px; display: block; }
.field-label .req { color: var(--red); margin-left: 2px; }
.search-group { display: flex; gap: 10px; }
.search-group .input { flex: 1; }

/* 开关 */
.switch { position: relative; width: 40px; height: 22px; flex: none; cursor: pointer; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .track { position: absolute; inset: 0; border-radius: 11px; background: #D6D9DD; transition: background 0.2s; }
.switch .track::after { content: ""; position: absolute; left: 2px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform 0.2s; box-shadow: 0 1px 3px rgba(0,0,0,0.18); }
.switch input:checked + .track { background: var(--green); }
.switch input:checked + .track::after { transform: translateX(18px); }

/* 复选框（表格用） */
.cb { width: 15px; height: 15px; accent-color: var(--green); cursor: pointer; vertical-align: -2px; }

/* ---------- 标签 / 徽章 ---------- */
.tag {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; line-height: 1; padding: 4px 8px; border-radius: 5px; white-space: nowrap;
}
.tag-green { background: var(--green-light); color: var(--green-active); }
.tag-orange { background: var(--orange-light); color: #D97400; }
.tag-red { background: var(--red-light); color: var(--red); }
.tag-blue { background: var(--blue-light); color: var(--blue); }
.tag-gray { background: var(--gray-tag); color: var(--text-2); }
.tag-dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }

/* ---------- 筛选 chips ---------- */
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; }
.filter-row { display: flex; align-items: center; gap: 8px; }
.filter-label { font-size: 13px; color: var(--text-2); flex: none; }
.chip {
  height: 28px; padding: 0 13px; border-radius: 6px; font-size: 13px;
  background: var(--bg-hover); color: var(--text-2); border: 1px solid transparent;
  transition: all 0.15s; display: inline-flex; align-items: center; gap: 5px;
}
.chip:hover { color: var(--text-1); }
.chip.active { background: var(--green-light); color: var(--green-active); border-color: var(--green-border); font-weight: 500; }
.chip-select { height: 28px; padding: 0 10px; border-radius: 6px; font-size: 12.5px; background: #fff; border: 1px solid var(--border); color: var(--text-1); appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='11' height='11' viewBox='0 0 24 24' fill='none' stroke='%238F959E' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 8px center; padding-right: 26px; cursor: pointer; }

/* ---------- 表格 ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 13px; }
.table th {
  background: var(--bg-hover); color: var(--text-2); font-weight: 500;
  text-align: left; padding: 10px 14px; white-space: nowrap;
  border-bottom: 1px solid var(--border-light);
}
.table td { padding: 12px 14px; border-bottom: 1px solid var(--border-light); vertical-align: middle; }
.table tbody tr { transition: background 0.12s; }
.table tbody tr:hover { background: #FAFBFC; }
.table tbody tr:last-child td { border-bottom: none; }
.table .cell-main { color: var(--text-1); }
.table .cell-sub { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.table .num { font-variant-numeric: tabular-nums; }
.table-empty { padding: 48px 0; text-align: center; color: var(--text-3); }
.table-empty svg { margin: 0 auto 10px; color: #C0C4CC; }

/* 分页 */
.pagination { display: flex; align-items: center; justify-content: flex-end; gap: 14px; padding: 14px 20px; border-top: 1px solid var(--border-light); font-size: 12.5px; color: var(--text-2); }
.pagination .pages { display: flex; align-items: center; gap: 4px; }
.pagination .pg {
  min-width: 26px; height: 26px; padding: 0 6px; border-radius: 6px; font-size: 12.5px;
  display: inline-flex; align-items: center; justify-content: center; color: var(--text-2);
}
.pagination .pg:hover { background: var(--bg-hover); }
.pagination .pg.active { background: var(--green); color: #fff; }
.pagination .pg[disabled] { opacity: 0.4; pointer-events: none; }

/* ---------- 统计卡（报表页） ---------- */
.stat-card {
  background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius);
  padding: 16px 18px 14px; position: relative; overflow: hidden; box-shadow: var(--shadow-card);
}
.stat-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--green); }
.stat-card .stat-label { font-size: 13px; color: var(--text-2); display: flex; align-items: center; gap: 5px; }
.stat-card .stat-value { font-size: 30px; font-weight: 650; margin-top: 8px; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.stat-card .stat-value .unit { font-size: 14px; font-weight: 400; color: var(--text-3); margin-left: 2px; }
.stat-card .stat-tip { font-size: 11.5px; color: var(--text-3); margin-top: 7px; display: flex; align-items: center; gap: 4px; }
.stat-card .stat-tip svg { color: var(--orange); flex: none; }
.stat-card.warn::before { background: var(--orange); }
.stat-card.warn .stat-value { color: #D97400; }

/* ---------- 图表 ---------- */
.chart-box { padding: 6px 12px 12px; }
.chart-box canvas { width: 100%; display: block; }
.chart-legend { display: flex; flex-direction: column; gap: 10px; padding: 4px 4px 4px 8px; min-width: 148px; }
.chart-legend .lg-item { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-2); }
.chart-legend .lg-sq { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.chart-legend .lg-val { margin-left: auto; font-weight: 600; color: var(--text-1); font-variant-numeric: tabular-nums; }
.chart-toggle { display: inline-flex; background: var(--bg-hover); border-radius: 7px; padding: 2px; }
.chart-toggle button { font-size: 12px; padding: 4px 10px; border-radius: 5px; color: var(--text-2); }
.chart-toggle button.active { background: #fff; color: var(--text-1); box-shadow: 0 1px 3px rgba(0,0,0,0.08); font-weight: 500; }

/* ---------- 上传区 ---------- */
.upload-box {
  border: 1.5px dashed #D6D9DD; border-radius: 10px; background: #FAFBFC;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  color: var(--text-3); cursor: pointer; transition: all 0.15s; min-height: 150px; padding: 18px;
}
.upload-box:hover { border-color: var(--green); background: var(--green-light); color: var(--green-active); }
.upload-box .up-icon { width: 42px; height: 42px; border-radius: 50%; background: #EFF1F3; display: flex; align-items: center; justify-content: center; color: #9A9FA8; }
.upload-box:hover .up-icon { background: #D9F3E4; color: var(--green); }
.photo-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.photo-item { position: relative; width: 88px; height: 88px; border-radius: 8px; overflow: hidden; border: 1px solid var(--border-light); }
.photo-item img { width: 100%; height: 100%; object-fit: cover; }
.photo-item .pv-remove {
  position: absolute; top: 4px; right: 4px; width: 18px; height: 18px; border-radius: 50%;
  background: rgba(0,0,0,0.55); color: #fff; display: flex; align-items: center; justify-content: center;
}
.photo-item .pv-remove:hover { background: var(--red); }
.photo-add {
  width: 88px; height: 88px; border-radius: 8px; border: 1.5px dashed #D6D9DD;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  color: var(--text-3); font-size: 11.5px; background: #FAFBFC;
}
.photo-add:hover { border-color: var(--green); color: var(--green); background: var(--green-light); }

/* ---------- 空状态 / 加载 ---------- */
.empty-box { text-align: center; padding: 44px 20px; color: var(--text-3); }
.empty-box .empty-icon { width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 50%; background: var(--bg-hover); display: flex; align-items: center; justify-content: center; color: #B4B8BF; }
.empty-box .empty-title { font-size: 14px; color: var(--text-2); margin-bottom: 6px; }
.empty-box .empty-desc { font-size: 12.5px; line-height: 1.7; }
.skeleton {
  background: linear-gradient(90deg, #F2F3F5 25%, #E9EAEC 37%, #F2F3F5 63%);
  background-size: 400% 100%; animation: shimmer 1.2s ease infinite; border-radius: 6px;
}
@keyframes shimmer { from { background-position: 100% 50%; } to { background-position: 0 50%; } }
.sk-line { height: 14px; margin-bottom: 10px; }
.sk-block { height: 90px; }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0; z-index: 200; background: rgba(31, 35, 41, 0.45);
  display: flex; align-items: flex-start; justify-content: center; padding: 8vh 20px 20px;
  animation: fadeIn 0.18s ease; overflow-y: auto;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: #fff; border-radius: 12px; width: 100%; box-shadow: var(--shadow-modal);
  animation: modalIn 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px 14px; border-bottom: 1px solid var(--border-light); }
.modal-title { font-size: 15.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.modal-close { width: 28px; height: 28px; border-radius: 6px; display: flex; align-items: center; justify-content: center; color: var(--text-3); }
.modal-close:hover { background: var(--bg-hover); color: var(--text-1); }
.modal-body { padding: 20px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px; border-top: 1px solid var(--border-light); }

/* ---------- Toast ---------- */
.toast-root { position: fixed; top: 24px; left: 50%; transform: translateX(-50%); z-index: 400; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  display: flex; align-items: center; gap: 8px; background: #fff; border-radius: 8px;
  padding: 10px 16px; font-size: 13.5px; box-shadow: 0 6px 24px rgba(31,35,41,0.14);
  border: 1px solid var(--border-light); animation: toastIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.toast.leaving { animation: toastOut 0.2s ease forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-8px); } }
.toast .t-icon { width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex: none; }
.toast-success .t-icon { background: var(--green); color: #fff; }
.toast-error .t-icon { background: var(--red); color: #fff; }
.toast-info .t-icon { background: var(--blue); color: #fff; }

/* ---------- 质检页专属 ---------- */
.check-search-card { padding: 22px 24px 18px; }
.check-search-title { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; margin-bottom: 14px; }
.check-search-title .scan-ico { width: 34px; height: 34px; border-radius: 9px; background: var(--green-light); color: var(--green); display: flex; align-items: center; justify-content: center; }
.check-hint { font-size: 12px; color: var(--text-3); margin-top: 8px; display: flex; align-items: center; gap: 5px; }
.check-hint svg { color: var(--orange); flex: none; }

.order-bar {
  display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: center;
  background: var(--green-light); border: 1px solid var(--green-border); border-radius: 10px;
  padding: 12px 18px; margin: 16px 0; font-size: 13px;
}
.order-bar .ob-item { display: flex; align-items: center; gap: 6px; }
.order-bar .ob-label { color: var(--text-2); }
.order-bar .ob-value { font-weight: 500; font-variant-numeric: tabular-nums; }

.sku-display { display: flex; gap: 18px; padding: 18px; }
.sku-img-wrap { position: relative; flex: none; width: 180px; }
.sku-img { width: 180px; height: 180px; border-radius: 10px; object-fit: cover; border: 1px solid var(--border-light); background: #fff; }
.sku-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%;
  background: rgba(255,255,255,0.92); border: 1px solid var(--border); color: var(--text-2);
  display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}
.sku-nav:hover { color: var(--green); border-color: var(--green); }
.sku-nav.prev { left: -12px; }
.sku-nav.next { right: -12px; }
.sku-info { flex: 1; min-width: 0; }
.sku-name { font-size: 16px; font-weight: 600; margin-bottom: 12px; }
.sku-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; font-size: 13px; }
.sku-meta .m-label { color: var(--text-3); margin-right: 8px; }
.sku-meta .m-value { color: var(--text-1); }
.sku-dots { display: flex; gap: 6px; justify-content: center; margin-top: 12px; }
.sku-dots .d { width: 6px; height: 6px; border-radius: 50%; background: #D6D9DD; }
.sku-dots .d.active { background: var(--green); width: 16px; border-radius: 3px; }

.result-group { margin-bottom: 16px; }
.result-group .rg-label { font-size: 13px; color: var(--text-2); margin-bottom: 9px; display: flex; align-items: center; gap: 6px; }
.result-group .rg-label::before { content: ""; width: 3px; height: 12px; border-radius: 2px; background: var(--green); }
.result-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.result-chips .r-chip {
  height: 32px; padding: 0 15px; border-radius: 7px; font-size: 13px;
  background: #fff; border: 1px solid var(--border); color: var(--text-1); transition: all 0.15s;
  display: inline-flex; align-items: center; gap: 5px;
}
.result-chips .r-chip:hover { border-color: var(--green); color: var(--green); }
.result-chips .r-chip.active { background: var(--green); border-color: var(--green); color: #fff; font-weight: 500; }
.result-chips .r-chip.active svg { color: #fff; }
.check-foot-note { text-align: center; font-size: 12px; color: var(--text-3); margin-top: 14px; display: flex; align-items: center; justify-content: center; gap: 5px; }
.check-foot-note svg { color: var(--orange); }

/* ---------- 平台配置页 ---------- */
.platform-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.platform-card {
  background: #fff; border: 1px solid var(--border-light); border-radius: var(--radius);
  padding: 16px; position: relative; box-shadow: var(--shadow-card); transition: box-shadow 0.2s, transform 0.2s;
}
.platform-card:hover { box-shadow: 0 6px 18px rgba(31,35,41,0.08); transform: translateY(-2px); }
.pc-close { position: absolute; top: 10px; right: 10px; width: 22px; height: 22px; border-radius: 5px; display: flex; align-items: center; justify-content: center; color: var(--text-3); }
.pc-close:hover { background: var(--red-light); color: var(--red); }
.platform-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.platform-logo { width: 34px; height: 34px; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 13px; flex: none; }
.platform-name { font-size: 14.5px; font-weight: 600; }
.platform-meta { font-size: 12px; color: var(--text-3); line-height: 1.9; }
.platform-meta b { font-weight: 500; color: var(--text-2); font-variant-numeric: tabular-nums; }
.platform-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--border-light); }
.security-note {
  display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: #D97400;
  background: var(--orange-light); border: 1px solid #FFE3B8; border-radius: 8px; padding: 10px 14px; margin-top: 16px;
}
.security-note svg { flex: none; }

/* ---------- 用户权限页 ---------- */
.users-layout { display: grid; grid-template-columns: 250px 1fr; gap: 16px; align-items: start; }
.role-list { padding: 6px; }
.role-item {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 12px;
  border-radius: 8px; text-align: left; transition: background 0.15s; font-size: 13.5px;
}
.role-item:hover { background: var(--bg-hover); }
.role-item.active { background: var(--green-light); color: var(--green-active); font-weight: 500; }
.role-item .r-ico { width: 28px; height: 28px; border-radius: 7px; background: var(--bg-hover); display: flex; align-items: center; justify-content: center; color: var(--text-2); flex: none; }
.role-item.active .r-ico { background: #fff; color: var(--green); }
.role-item .r-count { margin-left: auto; font-size: 12px; color: var(--text-3); }
.role-item.active .r-count { color: var(--green); }

.perm-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.perm-col { border: 1px solid var(--border-light); border-radius: 9px; padding: 14px; }
.perm-col .pc-title { font-size: 13.5px; font-weight: 600; margin-bottom: 12px; display: flex; align-items: center; gap: 7px; }
.perm-col .pc-title .t-ico { width: 22px; height: 22px; border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.perm-item { display: flex; align-items: center; gap: 9px; padding: 7px 0; font-size: 13px; color: var(--text-1); cursor: pointer; border-radius: 6px; }
.perm-item:hover { background: var(--bg-hover); }
.perm-item input { width: 15px; height: 15px; accent-color: var(--green); cursor: pointer; }

/* ---------- 详情页 ---------- */
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.kv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 20px; padding: 18px 20px; font-size: 13.5px; }
.kv-grid .kv { display: flex; gap: 10px; }
.kv-grid .k { color: var(--text-3); flex: none; min-width: 76px; }
.kv-grid .v { color: var(--text-1); word-break: break-all; }
.timeline { padding: 18px 20px; }
.tl-item { display: flex; gap: 12px; position: relative; padding-bottom: 18px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before { content: ""; position: absolute; left: 7px; top: 18px; bottom: 0; width: 1px; background: var(--border); }
.tl-item:last-child::before { display: none; }
.tl-dot { width: 15px; height: 15px; border-radius: 50%; border: 3px solid var(--green); background: #fff; flex: none; margin-top: 2px; }
.tl-dot.gray { border-color: #C0C4CC; }
.tl-dot.orange { border-color: var(--orange); }
.tl-body .tl-title { font-size: 13.5px; }
.tl-body .tl-time { font-size: 12px; color: var(--text-3); margin-top: 3px; }

/* ---------- 提示条 ---------- */
.tip-bar {
  display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #D97400;
  background: var(--orange-light); border: 1px solid #FFE3B8; border-radius: 8px; padding: 10px 14px; margin-top: 16px;
}
.tip-bar svg { flex: none; }
.tip-bar.green { color: var(--green-active); background: var(--green-light); border-color: var(--green-border); }
.tip-bar.green svg { color: var(--green); }

/* ---------- 杂项 ---------- */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-8 { gap: 8px; } .gap-10 { gap: 10px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; } .mt-20 { margin-top: 20px; }
.muted { color: var(--text-2); }
.muted-3 { color: var(--text-3); }
.fs-12 { font-size: 12px; } .fs-13 { font-size: 13px; }
.green-text { color: var(--green); }
.num { font-variant-numeric: tabular-nums; }
.divider { height: 1px; background: var(--border-light); margin: 14px 0; }

@media print {
  .sidebar, .page-actions, .no-print { display: none !important; }
  .main { margin-left: 0; }
  body { background: #fff; }
}
@media (max-width: 1100px) {
  .grid-4, .grid-stats, .platform-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-2, .grid-report, .detail-grid, .users-layout { grid-template-columns: 1fr; }
}

/* ---------- 项目文档页（ER 模型图 / 泳道流程图 / 架构图） ---------- */
.doc-card { padding: 0; overflow: hidden; }
.doc-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 13px 20px; border-bottom: 1px solid var(--border-light); }
.doc-toolbar-title { display: flex; align-items: center; gap: 7px; font-size: 13.5px; font-weight: 700; color: var(--text-1); }
.doc-toolbar-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.doc-chip { font-size: 11.5px; color: var(--text-2); background: var(--bg-hover); border: 1px solid var(--border-light); border-radius: 999px; padding: 3px 11px; }
.doc-chip-orange { color: #B45309; background: var(--orange-light); border-color: #F6D9B0; }
.doc-chip-green { color: var(--green-active); background: var(--green-light); border-color: var(--green-border); }
.svg-scroll { overflow-x: auto; background: #fff; }
.svg-scroll svg { max-width: 100%; height: auto; }
.doc-notes { margin-top: 16px; }
.doc-notes-title { display: flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 700; margin-bottom: 14px; }
.doc-notes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.doc-note { border: 1px solid var(--border-light); border-radius: var(--radius); padding: 14px 16px; background: var(--bg-hover); }
.doc-note b { display: block; font-size: 13px; margin-bottom: 6px; color: var(--text-1); }
.doc-note span { display: block; font-size: 12px; color: var(--text-2); line-height: 1.75; }
.doc-note-blue { background: #F5F9FF; border-color: #D8E7FC; }
.doc-note-orange { background: #FFFBF3; border-color: #F6E3BE; }
.doc-note-green { background: #F5FCF8; border-color: #CFEBDA; }
@media (max-width: 1100px) { .doc-notes-grid { grid-template-columns: 1fr; } }

/* ============================================================
 * 工具类补充（浏览器同步页等复用）
 * ============================================================ */
.text-green { color: var(--green); }
.text-blue { color: var(--blue); }
.text-orange { color: var(--orange); }
.text-muted { color: var(--text-3); }

/* ============================================================
 * 浏览器后台同步页（#/browser）
 * ============================================================ */
.browser-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
.browser-grid .card { margin: 0; }

/* 安装引导步骤 */
.guide-step {
  display: flex;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px dashed var(--border, #E5E7EB);
}
.guide-step:last-of-type { border-bottom: none; }
.guide-step b { display: block; font-size: 13.5px; margin-bottom: 3px; }
.guide-step .fs-13 { line-height: 1.65; }
.guide-step code {
  background: #F0F4F8;
  border-radius: 4px;
  padding: 1px 6px;
  font-size: 12px;
  color: #1a7f5a;
}
.guide-no {
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

/* Ingest Key */
.key-row { margin-bottom: 4px; }
.key-label { font-size: 13px; font-weight: 500; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.key-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #F7F9FA;
  border: 1px solid var(--border, #E5E7EB);
  border-radius: 8px;
  padding: 9px 12px;
}
.key-box code {
  flex: 1;
  font: 12.5px/1.4 Consolas, "Courier New", monospace;
  color: #1f2933;
  word-break: break-all;
}
.key-box .btn { flex: none; }

/* 同步模式单选 */
.mode-row { display: grid; gap: 10px; margin: 10px 0 8px; }
.mode-opt { display: flex; cursor: pointer; }
.mode-opt input { display: none; }
.mode-opt .mode-body {
  flex: 1;
  border: 1.5px solid var(--border, #E5E7EB);
  border-radius: 10px;
  padding: 11px 13px;
  transition: border-color .15s, background .15s;
}
.mode-opt .mode-body b { display: block; font-size: 13.5px; margin-bottom: 2px; }
.mode-opt .mode-body em { font-style: normal; font-size: 12px; color: var(--text-3); line-height: 1.5; }
.mode-opt input:checked + .mode-body {
  border-color: var(--green);
  background: var(--green-light);
}
.mode-opt input:checked + .mode-body b { color: var(--green-active); }

@media (max-width: 1100px) {
  .browser-grid { grid-template-columns: 1fr; }
}
