/* ==========================================================================
   后台通用样式（管理端 / 商家端共用）
   ========================================================================== */

.admin-body { background: var(--bg); }

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

.admin-side {
  width: 226px; flex: none;
  background: #0D1F1D; color: #A8BCB8;
  display: flex; flex-direction: column;
  position: fixed; inset: 0 auto 0 0; z-index: 300;
  transition: transform .25s var(--ease);
}
.admin-side-brand {
  height: 62px; display: flex; align-items: center; gap: 10px;
  padding: 0 18px; border-bottom: 1px solid rgba(255,255,255,.07); flex: none;
}
.admin-side-brand .logo-mark { width: 30px; height: 30px; border-radius: 8px; font-size: 15px; }
.admin-side-brand .bn { color: #fff; font-size: 15px; font-weight: 600; letter-spacing: .3px; }
.admin-side-brand .bt { font-size: 10px; color: #5E7B76; letter-spacing: .5px; }
.admin-side-nav { flex: 1; overflow-y: auto; padding: 12px 10px 24px; }
.admin-side-nav::-webkit-scrollbar { width: 5px; }
.admin-side-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 3px; }

.nav-group { margin-bottom: 6px; }
.nav-group-t {
  font-size: 10.5px; color: #4E6C67; letter-spacing: 1.2px;
  padding: 12px 12px 6px; text-transform: uppercase; font-weight: 600;
}
.side-link {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: var(--r-sm);
  font-size: 13.5px; color: #A8BCB8; margin-bottom: 1px;
  transition: all .14s var(--ease); position: relative;
}
.side-link .kzp-ico { opacity: .8; }
.side-link:hover { background: rgba(255,255,255,.06); color: #fff; }
.side-link.on { background: var(--brand); color: #fff; font-weight: 500; box-shadow: 0 2px 10px rgba(15,118,110,.4); }
.side-link.on .kzp-ico { opacity: 1; }
.side-badge {
  margin-left: auto; min-width: 19px; height: 18px; padding: 0 5px;
  border-radius: 999px; background: var(--danger); color: #fff;
  font-size: 11px; display: grid; place-items: center; font-weight: 600;
}
.side-link.on .side-badge { background: rgba(255,255,255,.28); }

.admin-side-ft { padding: 12px; border-top: 1px solid rgba(255,255,255,.07); flex: none; }
.side-user { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: var(--r-sm); }
.side-user .avatar { background: rgba(255,255,255,.1); color: #CFE0DD; width: 32px; height: 32px; }
.side-user .n { color: #fff; font-size: 13px; }
.side-user .r { color: #5E7B76; font-size: 11px; }

.admin-main { flex: 1; margin-left: 226px; min-width: 0; display: flex; flex-direction: column; }

.admin-top {
  height: 62px; background: rgba(255,255,255,.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px; padding: 0 24px;
  position: sticky; top: 0; z-index: 250; flex: none;
}
.admin-top h1 { font-size: 17px; font-weight: 600; }
.admin-top .sub { font-size: 12px; color: var(--ink-4); }
.admin-content { padding: 24px; flex: 1; }
.side-toggle { display: none; }

@media (max-width: 1000px) {
  .admin-side { transform: translateX(-100%); }
  .admin-side.open { transform: translateX(0); box-shadow: var(--sh-xl); }
  .admin-main { margin-left: 0; }
  .side-toggle { display: inline-flex; }
  .admin-content { padding: 16px; }
  .side-mask { position: fixed; inset: 0; background: rgba(22,33,31,.4); z-index: 290; }
}

/* 筛选栏 */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  padding: 14px 18px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-lg); margin-bottom: 18px;
}
.filter-bar .input, .filter-bar .select { min-height: 34px; height: 34px; width: auto; min-width: 150px; padding-top: 0; padding-bottom: 0; font-size: 13.5px; }
.filter-bar .search-box { min-width: 240px; height: 34px; background: var(--surface-2); border: 1px solid var(--line); }
.filter-bar .search-box:focus-within { background: #fff; }
.filter-sep { width: 1px; height: 22px; background: var(--line); }
.filter-tabs { display: flex; gap: 2px; background: var(--muted-bg); padding: 3px; border-radius: var(--r); }
.filter-tabs a {
  padding: 5px 12px; border-radius: var(--r-sm); font-size: 13px;
  color: var(--ink-3); transition: all .14s var(--ease); white-space: nowrap;
}
.filter-tabs a:hover { color: var(--brand); }
.filter-tabs a.on { background: var(--surface); color: var(--brand); font-weight: 600; box-shadow: var(--sh-xs); }

/* 详情页信息块 */
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.spec-table { font-size: 13.5px; }
.spec-table th {
  width: 120px; padding: 10px 14px; background: var(--surface-2);
  color: var(--ink-4); font-weight: 400; text-align: left;
  border: 1px solid var(--line-2); vertical-align: top;
}
.spec-table td { padding: 10px 14px; border: 1px solid var(--line-2); color: var(--ink-2); word-break: break-word; }

.img-strip { display: flex; flex-wrap: wrap; gap: 10px; }
.img-strip .is-item {
  width: 100px; height: 100px; border-radius: var(--r); overflow: hidden;
  border: 1px solid var(--line); position: relative; background: var(--muted-bg);
}
.img-strip .is-item img { width: 100%; height: 100%; object-fit: cover; }
.img-strip .is-item.is-cover { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand-50); }
.img-strip .is-item .cv {
  position: absolute; bottom: 0; left: 0; right: 0; height: 20px;
  background: var(--brand); color: #fff; font-size: 10px;
  display: grid; place-items: center;
}
.img-big {
  border-radius: var(--r); overflow: hidden; border: 1px solid var(--line);
  background: var(--muted-bg); max-width: 420px;
}
.img-big img { width: 100%; display: block; }

/* 审核面板 */
.audit-box {
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); overflow: hidden; margin-bottom: 20px;
}
.audit-box-hd {
  padding: 14px 20px; background: var(--warn-bg);
  border-bottom: 1px solid #F0DFA8;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.audit-box-hd .t { font-size: 14.5px; color: #8F6606; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.audit-box-bd { padding: 20px; }

.reason-list { display: flex; flex-direction: column; gap: 9px; margin-bottom: 16px; }
.reason-item {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 11px 14px; border: 1px solid var(--line); border-radius: var(--r);
  cursor: pointer; transition: all .14s var(--ease); background: var(--surface);
}
.reason-item:hover { border-color: var(--danger); background: var(--danger-bg); }
.reason-item .check-box { border-color: #C3CFCC; }
.reason-item .kzp-ico { color: var(--ink-4); margin-top: 2px; flex: none; }
.reason-item b { font-weight: 500; }

/* 审核预览态 */
.preview-shell {
  border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden;
  background: var(--surface);
}
.preview-bar {
  padding: 9px 16px; background: var(--surface-2); border-bottom: 1px solid var(--line);
  font-size: 12.5px; color: var(--ink-4);
  display: flex; align-items: center; gap: 8px;
}

/* 时间线 */
.timeline { position: relative; padding-left: 24px; }
.timeline::before {
  content: ''; position: absolute; left: 6px; top: 6px; bottom: 6px;
  width: 1.5px; background: var(--line);
}
.tl-item { position: relative; padding-bottom: 20px; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: ''; position: absolute; left: -22px; top: 5px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--line);
}
.tl-item.on::before { border-color: var(--brand); background: var(--brand); box-shadow: 0 0 0 3px var(--brand-50); }
.tl-t { font-size: 13.5px; font-weight: 500; }
.tl-c { font-size: 13px; color: var(--ink-3); margin-top: 2px; }
.tl-d { font-size: 11.5px; color: var(--ink-4); margin-top: 3px; }

/* 订单状态轨 */
.flow-track { display: flex; align-items: flex-start; gap: 0; margin: 8px 0 20px; }
.flow-node { display: flex; flex-direction: column; align-items: center; gap: 7px; flex: 1; position: relative; }
.flow-dot {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--muted-bg); color: var(--ink-4); border: 1.5px solid var(--line); z-index: 1;
}
.flow-node.done .flow-dot { background: var(--ok-bg); color: var(--ok); border-color: #A8DCC6; }
.flow-node.cur .flow-dot { background: var(--brand); color: #fff; border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-50); }
.flow-node:not(:last-child)::after {
  content: ''; position: absolute; top: 13px; left: 50%; width: 100%; height: 1.5px;
  background: var(--line);
}
.flow-node.done:not(:last-child)::after { background: #A8DCC6; }
.flow-lb { font-size: 11.5px; color: var(--ink-4); text-align: center; }
.flow-node.done .flow-lb, .flow-node.cur .flow-lb { color: var(--ink-2); }
.flow-node.cur .flow-lb { color: var(--brand); font-weight: 600; }

/* 内联两步确认（不使用弹窗） */
.confirm-inline {
  border: 1px solid #F3C8C8; background: var(--danger-bg);
  border-radius: var(--r); padding: 15px 17px; margin-top: 12px;
}
.confirm-inline .t { font-size: 13.5px; color: #A82F2F; font-weight: 500; margin-bottom: 10px; display: flex; align-items: center; gap: 7px; }

/* 图片编辑器 */
.img-editor { display: grid; grid-template-columns: 1fr 300px; gap: 20px; }
@media (max-width: 1000px) { .img-editor { grid-template-columns: 1fr; } }
.img-editor-stage {
  background: repeating-conic-gradient(#F2F5F4 0% 25%, #fff 0% 50%) 50% / 22px 22px;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  min-height: 380px; display: grid; place-items: center; padding: 20px; overflow: hidden;
}
.img-editor-stage img { max-width: 100%; max-height: 520px; object-fit: contain; box-shadow: var(--sh); }
.img-editor-tools { display: flex; flex-direction: column; gap: 18px; }
.tool-group { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.tool-group-hd {
  padding: 11px 15px; background: var(--surface-2); border-bottom: 1px solid var(--line-2);
  font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 7px;
}
.tool-group-hd .kzp-ico { color: var(--brand); }
.tool-group-bd { padding: 14px 15px; }

/* 登录页 */
.auth-page {
  min-height: 100vh; display: grid;
  grid-template-columns: 1.05fr .95fr;
  background: var(--bg);
}
.auth-visual {
  background: linear-gradient(150deg, #0B544E 0%, #0F766E 45%, #14A08F 100%);
  color: #fff; padding: 56px 60px; display: flex; flex-direction: column;
  position: relative; overflow: hidden;
}
.auth-visual::after {
  content: ''; position: absolute; right: -120px; bottom: -120px;
  width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.1), transparent 70%);
}
.auth-visual h2 { font-size: 30px; line-height: 1.4; margin-bottom: 16px; font-weight: 600; }
.auth-visual p { color: rgba(255,255,255,.82); font-size: 14.5px; line-height: 1.85; max-width: 440px; }
.auth-feature { display: flex; gap: 13px; margin-top: 26px; position: relative; z-index: 1; }
.auth-feature .kzp-ico { flex: none; margin-top: 2px; color: var(--brand-300); }
.auth-feature .ft { font-size: 13.5px; color: rgba(255,255,255,.88); }
.auth-feature .ft b { color: #fff; font-weight: 600; display: block; margin-bottom: 2px; font-size: 14px; }
.auth-stats { display: flex; gap: 38px; margin-top: auto; padding-top: 40px; position: relative; z-index: 1; }
.auth-stat .v { font-size: 27px; font-weight: 700; }
.auth-stat .k { font-size: 12px; color: rgba(255,255,255,.66); }

.auth-form-side { display: flex; align-items: center; justify-content: center; padding: 48px 40px; }
.auth-card { width: 100%; max-width: 428px; }
.auth-card h1 { font-size: 25px; margin-bottom: 6px; }
.auth-card .lead { color: var(--ink-3); font-size: 14px; margin-bottom: 28px; }

@media (max-width: 940px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-visual { display: none; }
  .auth-form-side { padding: 32px 20px; }
}

/* 头像上传 */
.avatar-up { display: flex; align-items: center; gap: 16px; }
.avatar-up .av-box {
  width: 72px; height: 72px; border-radius: 50%; overflow: hidden;
  border: 1px solid var(--line); background: var(--muted-bg);
  display: grid; place-items: center; flex: none; position: relative;
}
.avatar-up .av-box img { width: 100%; height: 100%; object-fit: cover; }

/* 面包导航式 tab */
.subtabs {
  display: flex; gap: 2px; border-bottom: 1px solid var(--line);
  margin-bottom: 20px; overflow-x: auto;
}
.subtabs a {
  padding: 10px 16px; font-size: 14px; color: var(--ink-3);
  border-bottom: 2px solid transparent; white-space: nowrap; transition: all .14s var(--ease);
}
.subtabs a:hover { color: var(--brand); }
.subtabs a.on { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }