/* ==========================================================================
   theme-legacy.css —— 老页面主题兼容层（Stripe 规格）
   作用：不改 HTML 结构，只覆盖已有类名，把 admin.php / print.php 换成新主题
   用法：在页面 </style> 之后引入，保证层叠顺序在后
   规格来源：awesome-design-md / stripe / DESIGN.md
   ========================================================================== */

/* ---------- 全局 ---------- */
html, body {
  background: #f6f9fc !important;
  color: #0d253d !important;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC",
               "Microsoft YaHei", "Segoe UI", sans-serif !important;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  left: 0; right: 0; top: 0;
  height: 340px;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(720px 250px at 12% -6%, rgba(83, 58, 253, .15), transparent 70%),
    radial-gradient(600px 230px at 44% -10%, rgba(249, 107, 238, .09), transparent 72%),
    radial-gradient(660px 240px at 76% -4%, rgba(14, 159, 110, .06), transparent 72%),
    radial-gradient(560px 220px at 96% 0%, rgba(234, 34, 97, .06), transparent 72%),
    linear-gradient(180deg, #fbfcff 0%, #f6f9fc 60%, #f6f9fc 100%);
}

a { color: #533afd; }
a:hover { color: #4434d4; }

/* ---------- 顶部横条：从紫色渐变改成白底细线 ---------- */
header.top {
  background: rgba(255, 255, 255, .9) !important;
  background-image: none !important;
  color: #0d253d !important;
  border-radius: 0 !important;
  border-bottom: 1px solid #e3e8ee !important;
  box-shadow: none !important;
  padding: 13px 22px !important;
  margin-bottom: 18px !important;
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
}
header.top h1 {
  font-size: 15.5px !important;
  font-weight: 600 !important;
  color: #0d253d !important;
  letter-spacing: -.2px;
}
header.top a {
  background: #ffffff !important;
  color: #533afd !important;
  border: 1px solid #e3e8ee !important;
  border-radius: 9999px !important;
  padding: 6px 14px !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  box-shadow: none !important;
}
header.top a:hover { border-color: #b9b9f9 !important; background: #fbfaff !important; }

/* ---------- 卡片 ---------- */
.card {
  background: #ffffff !important;
  border: 1px solid #e3e8ee !important;
  border-radius: 12px !important;
  box-shadow: 0 1px 3px rgba(0, 55, 112, .08) !important;
  padding: 20px !important;
  margin-bottom: 16px !important;
}
.card h2 {
  font-size: 14.5px !important;
  font-weight: 600 !important;
  color: #0d253d !important;
  letter-spacing: -.2px;
  margin-bottom: 14px !important;
}

/* 返回条 */
.backBar, .backbar {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 0 12px 0 !important;
  color: #64748d !important;
  font-size: 12.5px !important;
}
.backBar a { color: #533afd !important; }

/* ---------- 按钮：药丸 ---------- */
.btn {
  border-radius: 9999px !important;
  border: 1px solid #e3e8ee !important;
  background: #ffffff !important;
  color: #533afd !important;
  font-weight: 500 !important;
  font-size: 13px !important;
  padding: 8px 15px !important;
  box-shadow: none !important;
  transition: background .15s ease, border-color .15s ease, box-shadow .18s ease;
}
.btn:hover { background: #fbfaff !important; border-color: #b9b9f9 !important; box-shadow: 0 1px 3px rgba(0,55,112,.08) !important; }

.btn.pri {
  background: #533afd !important;
  border-color: transparent !important;
  color: #ffffff !important;
  box-shadow: 0 6px 18px rgba(83, 58, 253, .26) !important;
}
.btn.pri:hover { background: #665efd !important; }

.btn.ok    { background: #0e9f6e !important; border-color: transparent !important; color: #ffffff !important;
              box-shadow: 0 6px 18px rgba(14, 159, 110, .24) !important; }
.btn.ok:hover { background: #12b07b !important; }
.btn.danger{ background: #fdeef2 !important; border-color: #f8c8d6 !important; color: #d81b47 !important; }
.btn.danger:hover { background: #fbe0e8 !important; }
.btn.warn  { background: #fdf6e7 !important; border-color: #f2d9a8 !important; color: #b26a00 !important; }
.btn.ghost { background: #f0eeff !important; border-color: #b9b9f9 !important; color: #4434d4 !important; }
.btn.ghost:hover { background: #e8e4ff !important; }
.btn.sm { padding: 5px 12px !important; font-size: 12px !important; }

.lnk {
  color: #533afd !important;
  font-weight: 500 !important;
  background: none !important;
  border: 0 !important;
  padding: 0 4px !important;
}
.lnk.del { color: #d81b47 !important; }
.lnk:hover { text-decoration: underline; }

/* ---------- 表单 ---------- */
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
select,
textarea {
  border: 1px solid #cdd9e8 !important;
  border-radius: 6px !important;
  background: #ffffff !important;
  color: #0d253d !important;
  font-size: 13px !important;
  padding: 8px 11px !important;
  font-family: inherit !important;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
input:focus, select:focus, textarea:focus {
  border-color: #533afd !important;
  box-shadow: 0 0 0 3px rgba(83, 58, 253, .13) !important;
}
input[type="checkbox"], input[type="radio"] { accent-color: #533afd; }

.field label { color: #273951 !important; font-weight: 500 !important; }
.muted { color: #64748d !important; }
.err { color: #d81b47 !important; }

/* ---------- 表格 ---------- */
.stuTbl { border-collapse: collapse !important; }
.stuTbl thead th {
  background: #f6f9fc !important;
  color: #64748d !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  border-bottom: 1px solid #e3e8ee !important;
  padding: 9px 10px !important;
}
.stuTbl td {
  border-bottom: 1px solid #eef2f7 !important;
  padding: 9px 10px !important;
  color: #273951 !important;
  font-size: 13px !important;
}
.stuTbl tbody tr:last-child td { border-bottom: 0 !important; }
.stuTbl tr.item:hover td { background: #fafcff !important; }

.stuTbl tr.grp td {
  background: #f0f4fa !important;
  border-top: 1px solid #e3e8ee !important;
  border-bottom: 1px solid #e3e8ee !important;
}
.stuTbl tr.grp .gt { color: #0d253d !important; font-weight: 600 !important; }
.stuTbl tr.grp .gs { color: #64748d !important; }

.stuTbl .nm { color: #0d253d !important; font-weight: 500 !important; }
.stuTbl tr.item.dup td { background: #fffbf3 !important; }
.stuTbl .nm.same { color: #d81b47 !important; }

.stuTbl select {
  border-radius: 6px !important;
  padding: 5px 9px !important;
  font-size: 12.5px !important;
}
.stuTbl select.r.empty { color: #b3bdcc !important; }

/* ---------- 标签 ---------- */
.bdg {
  display: inline-flex !important;
  align-items: center;
  height: 21px;
  padding: 0 9px !important;
  border-radius: 9999px !important;
  background: #f0eeff !important;
  border: 1px solid #b9b9f9 !important;
  color: #4434d4 !important;
  font-size: 11.5px !important;
  font-weight: 500 !important;
}
.bdg.dup { background: #fdf6e7 !important; border-color: #f2d9a8 !important; color: #b26a00 !important; }
.bdg.tmp { background: #f6f9fc !important; border-color: #e3e8ee !important; color: #64748d !important; }
.bdg.perm{ background: #e8f8f2 !important; border-color: #b7e8d5 !important; color: #0e9f6e !important; }

/* ---------- Toast ---------- */
.toast {
  background: #0d253d !important;
  color: #ffffff !important;
  border-radius: 9999px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  padding: 11px 20px !important;
  box-shadow: 0 16px 44px rgba(0, 55, 112, .18) !important;
}

/* ---------- 打印页专属 ---------- */
.wrap { max-width: 1220px; }
.print .row, .card .row { gap: 9px; }

.item {
  border: 1px solid #e3e8ee !important;
  border-radius: 12px !important;
  transition: transform .16s ease, box-shadow .2s ease, border-color .16s ease;
}
.item:hover {
  transform: translateY(-2px);
  border-color: #b9b9f9 !important;
  box-shadow: 0 8px 24px rgba(0, 55, 112, .08), 0 2px 6px rgba(0, 55, 112, .04) !important;
}
.item.sel {
  border-color: #0e9f6e !important;
  box-shadow: 0 0 0 3px rgba(14, 159, 110, .16) !important;
}
.item .ck { border-radius: 50% !important; }
.item.sel .ck { background: #0e9f6e !important; border-color: #0e9f6e !important; }

.item .nt {
  background: linear-gradient(135deg, #ea2261, #f96bee) !important;
  border-radius: 9999px !important;
  font-weight: 600 !important;
  box-shadow: 0 4px 12px rgba(234, 34, 97, .28) !important;
}
.item .nt.empty { background: #eef2f7 !important; color: #8794a8 !important; box-shadow: none !important; }
.item .tc {
  background: #533afd !important;
  border-radius: 9999px !important;
  font-weight: 500 !important;
  box-shadow: 0 4px 12px rgba(83, 58, 253, .24) !important;
}
.item .nm { color: #64748d !important; }

/* 拖入区 */
#dropZone {
  border: 1.5px dashed #cdd9e8 !important;
  border-radius: 12px !important;
  background: linear-gradient(180deg, #fcfdff, #f6f9fc) !important;
  color: #64748d !important;
}
#dropZone b { color: #533afd !important; }
