* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.6 -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; color: #222; background: #f3f5f8; }
a { color: #1677ff; text-decoration: none; }
a:hover { text-decoration: underline; }
.top { display: flex; align-items: center; gap: 24px; padding: 0 24px; height: 56px; background: #fff; border-bottom: 1px solid #e5e8ee; position: sticky; top: 0; z-index: 9; }
.brand { font-weight: 600; font-size: 16px; color: #b8372d; }
.top nav { display: flex; gap: 4px; flex: 1; }
.top nav a { padding: 6px 14px; border-radius: 6px; color: #444; }
.top nav a.on, .top nav a:hover { background: #fdf0ee; color: #b8372d; text-decoration: none; }
.me { color: #888; }
.wrap { max-width: 1280px; margin: 20px auto; padding: 0 20px; }
.card { background: #fff; border-radius: 8px; padding: 18px 20px; margin-bottom: 16px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.card h3 { margin: 0 0 12px; font-size: 15px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.card-head h3 { margin: 0; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 9px 10px; border-bottom: 1px solid #f0f1f4; text-align: left; vertical-align: top; }
th { background: #fafbfc; font-weight: 500; color: #666; white-space: nowrap; }
.muted { color: #999; font-size: 12px; }
.empty { text-align: center; color: #aaa; padding: 30px; }
.nowrap { white-space: nowrap; }
.ellipsis { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn { display: inline-block; padding: 6px 14px; border: 1px solid #d9dce3; border-radius: 6px; background: #fff; color: #333; cursor: pointer; font-size: 13px; }
.btn:hover { border-color: #1677ff; color: #1677ff; text-decoration: none; }
.btn.primary { background: #1677ff; border-color: #1677ff; color: #fff; }
.btn.primary:hover { background: #4096ff; color: #fff; }
.btn.danger { color: #d4380d; border-color: #ffbb96; }
.btn.small { padding: 2px 8px; font-size: 12px; }
.btn.big { padding: 12px 40px; font-size: 16px; margin-top: 16px; }
.btn:disabled { opacity: .6; cursor: wait; }
input, select, textarea { padding: 6px 10px; border: 1px solid #d9dce3; border-radius: 6px; font: inherit; background: #fff; }
textarea { width: 100%; display: block; margin-top: 4px; }
label { display: block; margin-bottom: 14px; }
.mono { font-family: Consolas, Menlo, monospace; font-size: 12px; }
pre.mono { background: #f6f8fa; padding: 12px; border-radius: 6px; overflow: auto; max-height: 360px; }
.filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.inline { display: inline-flex; gap: 8px; align-items: center; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.actions form { margin: 0; }
.card-head .actions { margin-top: 0; }
.flash { padding: 10px 14px; border-radius: 6px; margin-bottom: 14px; }
.flash.ok { background: #f6ffed; border: 1px solid #b7eb8f; color: #389e0d; }
.flash.error { background: #fff2f0; border: 1px solid #ffccc7; color: #cf1322; }
.tip { background: #fffbe6; border: 1px solid #ffe58f; padding: 8px 14px; border-radius: 6px; margin-bottom: 16px; font-size: 13px; }
.error-text { color: #cf1322; font-size: 12px; margin-top: 4px; }
.tag { display: inline-block; padding: 0 8px; border-radius: 10px; font-size: 12px; background: #f0f0f0; color: #666; white-space: nowrap; }
.tag.pending { background: #e6f4ff; color: #1677ff; }
.tag.approved { background: #f6ffed; color: #389e0d; }
.tag.rejected, .tag.oa_failed { background: #fff2f0; color: #cf1322; }
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-bottom: 16px; }
.stat { background: #fff; border-radius: 8px; padding: 18px 20px; color: #666; }
.stat:hover { text-decoration: none; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.stat b { display: block; font-size: 26px; color: #222; }
.stat.warn b { color: #cf1322; }
.kv { display: grid; grid-template-columns: 120px 1fr; gap: 8px 16px; margin: 0; }
.kv dt { color: #888; }
.kv dd { margin: 0; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
code.log { font-size: 12px; word-break: break-all; color: #555; display: block; max-height: 120px; overflow: auto; }
.pager { display: flex; gap: 16px; justify-content: center; padding-top: 14px; }
.org { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }
.dept-list ul { list-style: none; margin: 0; padding: 0; max-height: calc(100vh - 260px); overflow: auto; }
.dept-list li { display: flex; justify-content: space-between; padding: 6px 8px; border-radius: 4px; }
.dept-list li.on { background: #e6f4ff; }
.dept-list li.hidden-dept a { color: #aaa; text-decoration: line-through; }
.switch { width: 36px; height: 20px; border-radius: 10px; border: 0; background: #ccc; position: relative; cursor: pointer; }
.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: .2s; }
.switch.on { background: #1677ff; }
.switch.on::after { left: 18px; }
.banners { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.banner { width: 200px; }
.banner img { width: 200px; height: 125px; object-fit: cover; border-radius: 6px; display: block; margin-bottom: 4px; }
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; flex-direction: column; }
.login-box { width: 340px; padding: 30px; }
.login-box h2 { text-align: center; margin: 0 0 24px; color: #b8372d; }
.login-box input { width: 100%; margin-top: 4px; padding: 9px 12px; }
.login-box .btn { width: 100%; padding: 10px; font-size: 15px; }
.verify { max-width: 640px; margin: 0 auto; text-align: center; }
.verify .kv { text-align: left; margin: 16px 0; }
.verify-result { font-size: 28px; font-weight: 600; padding: 20px; border-radius: 8px; margin-bottom: 12px; }
.verify-result.good { background: #f6ffed; color: #389e0d; }
.verify-result.bad { background: #fff2f0; color: #cf1322; }
@media (max-width: 800px) {
  .top { flex-wrap: wrap; height: auto; padding: 8px 12px; gap: 8px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .org, .grid2 { grid-template-columns: 1fr; }
  .wrap { padding: 0 10px; }
}
