* { box-sizing: border-box; }
body {
  margin: 0;
  color: #163a66;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: linear-gradient(180deg, #e7f3fc 0%, #f7fbfe 280px, #e8f4fc 100%);
}
a { color: #2563eb; }
button, input, select, textarea { font: inherit; }
.page { max-width: 1440px; margin: 0 auto; padding: 16px 18px 32px; }

.alert { margin: 0 0 12px; padding: 10px 14px; border-radius: 10px; font-size: 13px; }
.alert.ok { background: #ecfdf3; color: #15803d; }
.alert.err { background: #fef2f2; color: #b91c1c; }

.topbar, .card, .panel, .kpi, .notice-bar {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(56, 132, 210, .08);
}
.topbar { padding: 16px 20px 12px; margin-bottom: 14px; }
.brand-row { display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; text-decoration: none; color: inherit; }
.logo {
  width: 46px; height: 46px; border-radius: 14px; flex: none;
  display: grid; place-items: center;
  background: linear-gradient(180deg, #4b93ff, #2f6bff);
}
.brand h1 { margin: 0; font-size: 22px; line-height: 1.25; }
.brand h1 span { margin-left: 8px; color: #6d88a8; font-size: 14px; font-weight: 500; }
.brand p { margin: 3px 0 0; color: #93a8c2; font-size: 11px; letter-spacing: 1.2px; }
.top-side { margin-left: auto; display: flex; align-items: center; gap: 16px; flex: none; }
.today { display: flex; align-items: center; gap: 6px; color: #6d88a8; font-size: 13px; }
.today b { color: #2f6bff; font-size: 16px; }
.range { display: flex; align-items: center; gap: 8px; color: #6d88a8; font-size: 13px; }
.range select, .filters select, .filters input {
  height: 32px; border: 1px solid #d7e4f2; border-radius: 8px; padding: 0 8px; color: #163a66; background: #fff;
}
.nav-row { display: flex; align-items: center; gap: 4px; margin-top: 12px; padding-top: 10px; border-top: 1px solid #eef3f8; }
.nav { color: #4b6484; text-decoration: none; padding: 6px 12px; border-radius: 999px; font-size: 13px; }
.nav.on, .nav:hover { background: #e8f2ff; color: #1d4ed8; }
.who { margin-left: auto; display: flex; align-items: center; gap: 10px; color: #6d88a8; font-size: 13px; }
.who b { color: #163a66; }
.logout { color: #ef4444; text-decoration: none; }

.notice-bar { display: flex; gap: 12px; align-items: flex-start; padding: 10px 14px; margin-bottom: 14px; }
.notice-tag { background: #e8f1ff; color: #2f6bff; border-radius: 8px; padding: 4px 8px; font-size: 12px; font-weight: 700; }
.notice-list p { margin: 0 0 4px; font-size: 13px; color: #3e5878; }
.notice-list p:last-child { margin: 0; }

.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)) 1.2fr; gap: 14px; }
.kpi { display: flex; align-items: center; gap: 12px; padding: 16px 14px; min-height: 108px; color: inherit; text-decoration: none; }
a.kpi:hover { box-shadow: 0 12px 28px rgba(47, 123, 255, .16); }
.kpi-icon { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; flex: none; }
.kpi-icon.doc { background: #e8f1ff; }
.kpi-icon.ok { background: #e8fbf1; }
.kpi-icon.run { background: #e8f1ff; }
.kpi-icon.late { background: #fff1f0; }
.kpi-icon.wait { background: #e8f7ff; }
.kpi-label { color: #7d93ad; font-size: 13px; }
.kpi-num { margin-top: 2px; font-size: 30px; font-weight: 750; line-height: 1.1; letter-spacing: -.4px; }
.kpi-num small { margin-left: 2px; font-size: 14px; font-weight: 650; }
.kpi-sub { margin-top: 4px; font-size: 12px; }
.kpi-sub.ok { color: #16a34a; }
.kpi-sub.run { color: #2563eb; }
.kpi-sub.late { color: #ea580c; }
.kpi-sub.wait { color: #94a3b8; }
.banner {
  position: relative; overflow: hidden; min-height: 108px; padding: 16px 16px 0;
  background: linear-gradient(135deg, #1f6bff 0%, #3d92ff 55%, #7ec8ff 100%);
  box-shadow: 0 10px 30px rgba(47, 123, 255, .18);
}
.banner-text { position: relative; z-index: 1; color: #fff; font-size: 22px; font-weight: 750; line-height: 1.35; text-shadow: 0 2px 8px rgba(12, 58, 140, .2); }
.banner-art { position: absolute; right: 0; bottom: 0; width: 78%; height: 78%; }

.charts { display: grid; grid-template-columns: .95fr 1.05fr 1.15fr 1.05fr; gap: 14px; margin-top: 14px; }
.card { padding: 16px 16px 12px; }
.card-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.card-title h3, .mark { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 15px; font-weight: 700; }
.card-title h3::before, .mark::before {
  content: ""; width: 8px; height: 8px; border-radius: 2px; background: #2f7bff; box-shadow: 0 0 0 3px rgba(47, 123, 255, .12);
}
.donut-wrap { position: relative; width: 176px; height: 176px; margin: 8px auto 14px; }
.donut { width: 100%; height: 100%; border-radius: 50%; }
.donut-hole {
  position: absolute; inset: 32px; background: #fff; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.donut-hole strong { font-size: 28px; line-height: 1; }
.donut-hole span { margin-top: 2px; color: #8aa0b8; font-size: 12px; }
.legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 12px; color: #5c7290; font-size: 12px; }
.legend a { color: inherit; text-decoration: none; }
.legend a:hover { color: #1d4ed8; }
.legend.tight { justify-content: flex-end; }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 4px; }
.legend .c-plan { background: #60a5fa; }
.legend .c-act { background: #34d399; }
.type-list { display: flex; flex-direction: column; gap: 12px; padding-top: 6px; }
.bar-row { display: grid; grid-template-columns: 52px 1fr 22px; gap: 8px; align-items: center; color: inherit; text-decoration: none; border-radius: 8px; }
a.bar-row:hover .bar-label { color: #1d4ed8; }
.bar-label { color: #5c7290; font-size: 13px; }
.bar-track { height: 10px; background: #eef3f8; border-radius: 99px; overflow: hidden; }
.bar-track i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #8ec8ff, #2f7bff); }
.bar-num { text-align: right; font-weight: 700; }
.cmp { display: grid; grid-template-columns: 78px 1fr 42px; gap: 8px; align-items: center; margin-bottom: 10px; color: inherit; text-decoration: none; border-radius: 8px; }
a.cmp:hover .cmp-name { color: #1d4ed8; }
.cmp-name { color: #5c7290; font-size: 13px; }
.cmp-bars { display: flex; flex-direction: column; gap: 5px; }
.track { height: 8px; background: #eef3f8; border-radius: 99px; overflow: hidden; }
.track i { display: block; height: 100%; border-radius: 99px; }
.track i.plan { background: #60a5fa; }
.track i.act { background: #34d399; }
.cmp-pct { display: flex; flex-direction: column; gap: 2px; font-size: 12px; text-align: right; }
.cmp-pct .plan { color: #3b82f6; }
.cmp-pct .act { color: #16a34a; }
.block-label { display: flex; align-items: center; justify-content: space-between; margin: 12px 0 6px; padding-top: 10px; border-top: 1px solid #f2f6fb; }
.right-card .block-label:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.block-label span, .top-main small, .empty, .help { color: #8aa0b8; font-size: 12px; font-weight: 400; }
.top-row, .mile-row { display: grid; grid-template-columns: 22px 1fr auto; gap: 8px; align-items: center; padding: 7px 0; color: inherit; text-decoration: none; border-radius: 8px; }
a.top-row:hover, a.mile-row:hover { background: #f5f9ff; }
.mile-row { grid-template-columns: 1fr auto auto; }
.rank { width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; color: #fff; font-size: 12px; font-weight: 700; background: #93c5fd; }
.rank.r1 { background: #ff5d5d; }
.rank.r2 { background: #ff9f2f; }
.rank.r3 { background: #60a5fa; }
.top-main { min-width: 0; display: flex; flex-direction: column; }
.top-main b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-days { font-size: 18px; font-weight: 750; line-height: 1; }
.top-days small { margin-left: 1px; font-size: 12px; font-weight: 500; }
.top-days.late { color: #ff8a1e; }
.top-days.ahead { color: #16a34a; }
.mile-date { color: #8aa0b8; font-size: 12px; }
.mile-left { min-width: 46px; padding: 4px 6px; border-radius: 8px; background: #eef6ff; color: #2f7bff; text-align: center; }
.mile-left b { display: block; font-size: 14px; line-height: 1; }
.mile-left small { font-size: 11px; }

.board { margin-top: 14px; scroll-margin-top: 16px; }
table.board-table tr[data-href] { cursor: pointer; }
table.board-table td a { color: inherit; text-decoration: none; }
table.board-table td.name a { color: #2563eb; }
table.board-table td a:hover { text-decoration: underline; }
a.st { text-decoration: none; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.filters label { display: flex; align-items: center; gap: 6px; color: #6d88a8; font-size: 13px; }
.filters input { width: 180px; }
.table-wrap { overflow: auto; }
table.board-table { width: 100%; border-collapse: collapse; min-width: 1280px; font-size: 12px; }
table.board-table th { background: #f4f8fc; color: #7b90a8; font-weight: 650; text-align: center; padding: 10px 6px; white-space: nowrap; }
table.board-table td { padding: 9px 6px; border-bottom: 1px solid #eef3f8; text-align: center; white-space: nowrap; color: #243e5e; }
table.board-table td.name { text-align: left; font-weight: 650; }
table.board-table td.name a { text-decoration: none; }
table.board-table td.remark { max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
table.board-table tr:hover td { background: #f8fbfe; }
.mini { display: flex; align-items: center; justify-content: center; gap: 6px; }
.mini .track { width: 54px; }
.mini em { font-style: normal; min-width: 32px; text-align: left; color: #5c7290; }
.mini.ok .track i { background: #34d399; }
.mini.run .track i { background: #3b82f6; }
.mini.late .track i { background: #fb923c; }
.mini.wait .track i { background: #cbd5e1; }
.st { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; font-style: normal; }
.st.ok { background: #e8fbf1; color: #16a34a; }
.st.run { background: #e8f1ff; color: #2563eb; }
.st.late { background: #fff4e8; color: #ea7a0c; }
.st.wait { background: #f1f5f9; color: #64748b; }
.late-num { color: #ea7a0c; font-weight: 700; }

.panel { padding: 18px 20px 20px; margin-bottom: 14px; }
.panel.narrow { max-width: 560px; }
.panel-head, .ops { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.panel-head h2, .panel h2, .split h2 { margin: 0; font-size: 18px; }
.filters { margin-bottom: 12px; }
table.data { width: 100%; border-collapse: collapse; font-size: 13px; }
table.data th { text-align: left; background: #f5f9fd; color: #6b829b; font-weight: 650; padding: 10px; white-space: nowrap; }
table.data td { padding: 10px; border-bottom: 1px solid #eef3f8; vertical-align: middle; }
table.data .ops { justify-content: flex-start; }
.ops form { margin: 0; }
.ops button, .file-list button { background: none; border: 0; color: #ef4444; cursor: pointer; padding: 0; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; height: 34px; padding: 0 14px;
  border-radius: 8px; border: 1px solid #2f7bff; background: #2f7bff; color: #fff; text-decoration: none; font-size: 13px; cursor: pointer;
}
.btn.small { height: 32px; padding: 0 12px; }
.btn.ghost { background: #fff; color: #2f7bff; }
.btn.block { width: 100%; height: 40px; margin-top: 6px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { color: #5c7290; font-size: 13px; }
.field > input:not([type="range"]):not([type="file"]):not([type="checkbox"]),
.field > select, .field > textarea {
  width: 100%; height: 36px; border: 1px solid #d7e4f2; border-radius: 8px; padding: 0 10px; color: #163a66; background: #fff; outline: none;
}
.field > textarea { height: 96px; padding: 8px 10px; resize: vertical; }
.field > input:focus, .field > select:focus, .field > textarea:focus { border-color: #2f7bff; box-shadow: 0 0 0 3px rgba(47, 123, 255, .12); }
.field input[readonly] { background: #f5f8fb; }
.form-actions { display: flex; gap: 10px; margin-top: 16px; }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }
.check { display: flex; gap: 8px; align-items: flex-start; color: #1c3d66; font-size: 13px; }
.help { display: block; margin-top: 6px; }
.meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px 16px; }
.meta span { display: block; margin-bottom: 4px; }
.meta b { font-weight: 700; }
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: 14px; }
.split .panel h2 { margin-bottom: 12px; }
.gap { margin-top: 18px; }
.file-list, .log-list { list-style: none; margin: 0; padding: 0; }
.file-list li, .log-list li { padding: 10px 0; border-bottom: 1px solid #eef3f8; }
.file-list li { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; }
.file-list a { word-break: break-all; }
.log-list b { margin-right: 8px; }
.log-list p { margin: 4px 0 0; color: #3e5878; }

.login-wrap { min-height: calc(100vh - 48px); display: grid; place-items: center; }
.login-card { width: min(420px, 100%); padding: 32px 32px 26px; }
.login-card h1 { margin: 12px 0 4px; font-size: 22px; }
.login-card .en { margin-bottom: 18px; color: #8aa0b8; font-size: 12px; letter-spacing: 1px; }
.login-card .field { margin-bottom: 12px; }
.hint { margin-top: 16px; padding: 12px 14px; border-radius: 12px; background: #f5f9fd; color: #5c7290; font-size: 12px; line-height: 1.7; }
.hint b { color: #163a66; }
.empty { padding: 8px 0; }

@media (max-width: 1200px) {
  .kpis, .charts, .split, .meta { grid-template-columns: 1fr 1fr; }
  .banner { grid-column: 1 / -1; }
  .brand h1 span { display: none; }
}
@media (max-width: 760px) {
  .kpis, .charts, .split, .meta, .form-grid, .checks { grid-template-columns: 1fr; }
  .brand-row, .top-side, .nav-row { flex-wrap: wrap; }
  .who { margin-left: 0; }
}
