/* 翼起学 · 网页管理后台 —— 样式（2026-10-27 改版）
 * 设计参考：校如云后台（深色分组侧栏 + 彩色指标卡 + 白底内容区）
 * 主色 #0eb87f（与小程序品牌一致）
 */
:root {
  --primary: #0eb87f;
  --primary-d: #0aa06d;
  --primary-l: #e6f8f1;
  --ink: #1d2b3a;
  --ink-2: #475467;
  --ink-3: #8b98a9;
  --line: #e8edf3;
  --bg: #f4f6fa;
  --white: #fff;
  --side-bg: linear-gradient(180deg, #16233a 0%, #101a2c 100%);
  --side-w: 224px;
  --side-w-mini: 68px;
  --r: 14px;
  --shadow: 0 1px 2px rgba(16, 26, 44, .04), 0 8px 24px -12px rgba(16, 26, 44, .12);
  --el-color-primary: #0eb87f;
  --el-color-primary-light-3: #4fcca4;
  --el-color-primary-light-5: #87ddc0;
  --el-color-primary-light-7: #b8ecdb;
  --el-color-primary-light-8: #d5f4e9;
  --el-color-primary-light-9: #eafaf4;
  --el-color-primary-dark-2: #0aa06d;
  --el-border-radius-base: 8px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0; height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

#app { height: 100%; }

/* ============ 启动页 ============ */
.boot {
  height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  background: radial-gradient(1200px 600px at 50% 0%, #e8fbf4 0%, #f4f6fa 60%);
}
.boot-logo {
  width: 68px; height: 68px; border-radius: 20px;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, #16c98b, #079e6c);
  box-shadow: 0 14px 30px -10px rgba(14, 184, 127, .6);
  animation: bootPulse 1.6s ease-in-out infinite;
}
@keyframes bootPulse {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-4px) scale(1.03); }
}
.boot-text { color: var(--ink-3); font-size: 13px; letter-spacing: .5px; }

/* ============ 骨架布局 ============ */
.layout { display: flex; height: 100vh; overflow: hidden; }

/* ---------- 侧栏 ---------- */
.side {
  width: var(--side-w); flex: 0 0 var(--side-w);
  background: var(--side-bg);
  display: flex; flex-direction: column;
  transition: width .2s ease, flex-basis .2s ease;
  position: relative;
  z-index: 5;
}
.side::after {
  content: ''; position: absolute; top: 0; right: 0; width: 1px; height: 100%;
  background: rgba(255, 255, 255, .06);
}
.side.collapsed { width: var(--side-w-mini); flex: 0 0 var(--side-w-mini); }

.brand {
  height: 64px; flex: 0 0 64px;
  display: flex; align-items: center; gap: 10px;
  padding: 0 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .07);
}
.side.collapsed .brand { padding: 0 16px; justify-content: center; }
.brand-mark {
  width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, #17cf8f, #069c6a);
  box-shadow: 0 6px 14px -6px rgba(14, 184, 127, .9);
}
.brand-text {
  color: #fff; font-size: 15px; font-weight: 600; letter-spacing: .5px;
  line-height: 1.2; white-space: nowrap; overflow: hidden;
}
.brand-text small { display: block; font-size: 11px; font-weight: 400; color: #7d8ca6; letter-spacing: 0; margin-top: 2px; }

.nav { flex: 1; overflow-y: auto; padding: 14px 10px 10px; }
.nav::-webkit-scrollbar { width: 0; }
.nav-group {
  padding: 12px 12px 6px;
  font-size: 11px; color: #5d6f8c; letter-spacing: 1px; font-weight: 600;
}
.nav-item {
  display: flex; align-items: center; gap: 11px;
  height: 42px; padding: 0 12px; margin-bottom: 3px;
  border-radius: 10px;
  color: #b9c6d9; font-size: 14px; cursor: pointer;
  user-select: none; white-space: nowrap; overflow: hidden;
  transition: background .16s, color .16s;
}
.nav-item:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.nav-item.active {
  background: linear-gradient(135deg, #10c185, #0aa571);
  color: #fff; font-weight: 600;
  box-shadow: 0 8px 18px -8px rgba(14, 184, 127, .95);
}
.nav-ico {
  width: 18px; height: 18px; flex: 0 0 18px;
  fill: none; stroke: currentColor; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}
.side.collapsed .nav-item { justify-content: center; padding: 0; }
.side.collapsed .nav { padding: 14px 10px; }

.side-foot {
  padding: 14px 18px;
  border-top: 1px solid rgba(255, 255, 255, .07);
  font-size: 11px; color: #5d6f8c; display: flex; align-items: center; gap: 7px;
  letter-spacing: .3px;
}
.sync-dot {
  width: 6px; height: 6px; border-radius: 50%; background: #17cf8f; flex: 0 0 6px;
  box-shadow: 0 0 0 3px rgba(23, 207, 143, .18);
}

/* ---------- 主区 ---------- */
.body { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  height: 64px; flex: 0 0 64px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 22px;
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 4;
}
.tb-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.collapse-btn {
  width: 32px; height: 32px; border: 0; border-radius: 8px; cursor: pointer;
  background: transparent; color: var(--ink-2);
  display: flex; align-items: center; justify-content: center;
  transition: background .16s, color .16s;
}
.collapse-btn:hover { background: var(--primary-l); color: var(--primary-d); }
.collapse-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.page-title { font-size: 17px; font-weight: 650; color: var(--ink); letter-spacing: .3px; }

.tb-right { display: flex; align-items: center; gap: 12px; }
.tb-lbl { font-size: 12px; color: var(--ink-3); }
.user-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 4px 12px 4px 4px;
  background: #f4f6fa; border-radius: 999px;
}
.avatar {
  width: 28px; height: 28px; flex: 0 0 28px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; color: #fff;
  background: linear-gradient(135deg, #17cf8f, #089e6c);
}
.avatar-sm { width: 24px; height: 24px; flex: 0 0 24px; font-size: 11px; }
.user-name { font-size: 13px; font-weight: 600; color: var(--ink); }
.user-role { font-size: 11px; color: var(--ink-3); padding-left: 2px; }
.logout-btn { color: var(--ink-3) !important; }

.campus-switch .el-radio-button__inner { border-color: var(--line); }

.main { flex: 1; overflow-y: auto; padding: 20px 22px 28px; }
.main::-webkit-scrollbar { width: 8px; }
.main::-webkit-scrollbar-thumb { background: #d5dde8; border-radius: 4px; }
.main::-webkit-scrollbar-track { background: transparent; }

/* ============ 登录 ============ */
.login-wrap { display: flex; height: 100vh; background: #fff; }
.login-brand {
  flex: 1.15; position: relative; overflow: hidden;
  background: linear-gradient(150deg, #10223a 0%, #0b3550 55%, #076048 100%);
  display: flex; align-items: center; justify-content: center;
}
.login-brand::before {
  content: ''; position: absolute; width: 620px; height: 620px; border-radius: 50%;
  right: -220px; top: -240px;
  background: radial-gradient(circle, rgba(23, 207, 143, .30), transparent 68%);
}
.login-brand::after {
  content: ''; position: absolute; width: 480px; height: 480px; border-radius: 50%;
  left: -180px; bottom: -200px;
  background: radial-gradient(circle, rgba(78, 138, 244, .24), transparent 70%);
}
.lb-inner { position: relative; z-index: 1; padding: 0 56px; max-width: 460px; }
.lb-logo {
  width: 58px; height: 58px; border-radius: 17px;
  display: flex; align-items: center; justify-content: center;
  font-size: 27px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, #1ad392, #069c6a);
  box-shadow: 0 16px 34px -12px rgba(10, 160, 109, .9);
  margin-bottom: 22px;
}
.lb-name { font-size: 34px; font-weight: 700; color: #fff; letter-spacing: 3px; }
.lb-sub { font-size: 13px; color: #93a9c4; margin-top: 10px; letter-spacing: 1px; }
.lb-feats { margin-top: 40px; display: flex; flex-direction: column; gap: 15px; }
.lb-feat { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: #b9c9dc; }
.lb-feat .dot {
  width: 7px; height: 7px; border-radius: 50%; flex: 0 0 7px;
  background: #1ad392; box-shadow: 0 0 0 4px rgba(26, 211, 146, .16);
}

.login-form-side { flex: 1; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { width: 100%; max-width: 366px; }
.lc-title { font-size: 24px; font-weight: 700; color: var(--ink); }
.lc-sub { font-size: 13px; color: var(--ink-3); margin: 8px 0 26px; }
.login-card .el-form-item { margin-bottom: 16px; }
.login-card .el-divider--horizontal { margin: 30px 0 6px; }
.login-card .el-divider__text { font-size: 12.5px; white-space: nowrap; }
.login-card .el-form-item__label { font-size: 12.5px; color: var(--ink-2); padding-bottom: 5px !important; }
.login-btn {
  width: 100%; margin-top: 18px; height: 44px;
  font-size: 15px; letter-spacing: 4px; border-radius: 10px;
  box-shadow: 0 10px 22px -10px rgba(14, 184, 127, .9);
}
.init-box {
  background: #f8fafc; border: 1px dashed #cfd9e6; border-radius: 12px;
  padding: 14px; display: flex; flex-direction: column; gap: 9px;
}
.init-title { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.tip { font-size: 11.5px; color: var(--ink-3); line-height: 1.6; }

/* ============ 通用 ============ */
.muted { color: var(--ink-3); font-size: 12.5px; }
.spacer { flex: 1; }
.mt12 { margin-top: 12px; }
.mt14 { margin-top: 14px; }
.mb12 { margin-bottom: 12px; }
.c-warn { color: #f59a23; font-weight: 600; }
.c-bad { color: #f25555; font-weight: 600; }

.panel {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r);
  padding: 16px 18px; box-shadow: var(--shadow);
}
.panel-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 650; color: var(--ink);
  margin-bottom: 14px;
}
.panel-sub { font-size: 11.5px; font-weight: 400; color: var(--ink-3); }
.panel-empty { color: var(--ink-3); font-size: 12.5px; padding: 16px 0; text-align: center; }

.filter-bar {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r);
  padding: 12px 14px; margin-bottom: 14px; box-shadow: var(--shadow);
}
.pager { display: flex; justify-content: flex-end; padding: 14px 2px 0; }

.el-table { --el-table-border-color: var(--line); --el-table-header-bg-color: #f8fafc; }
.el-table th.el-table__cell { background: #f8fafc !important; color: var(--ink-2); font-weight: 600; font-size: 12.5px; }
.click-table .el-table__row { cursor: pointer; }
.el-table__row:hover > td { background: #f6fbf9 !important; }

/* ============ 工作台 ============ */
.dash-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }

.kpi-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px;
}

.kpi-card {
  position: relative; overflow: hidden;
  display: flex; align-items: flex-start; gap: 11px;
  padding: 15px 14px;
  background: var(--white);
  border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow);
  transition: transform .18s, box-shadow .18s;
}
.kpi-card:hover { transform: translateY(-2px); box-shadow: 0 2px 6px rgba(16,26,44,.05), 0 16px 30px -14px rgba(16,26,44,.22); }
.kpi-card::after {
  content: ''; position: absolute; right: -30px; bottom: -34px;
  width: 86px; height: 86px; border-radius: 50%;
  background: currentColor; opacity: .06;
}
.kpi-ico {
  width: 38px; height: 38px; flex: 0 0 38px; border-radius: 11px;
  display: flex; align-items: center; justify-content: center;
}
.kpi-ico svg { width: 19px; height: 19px; }
.kpi-body { flex: 1; min-width: 0; }
.kpi-label { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; }
.kpi-num { font-size: 25px; font-weight: 700; line-height: 1.25; margin-top: 1px; color: var(--ink); font-variant-numeric: tabular-nums; }
.kpi-camps { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 3px; }
.kpi-camps span { font-size: 10.5px; color: var(--ink-3); white-space: nowrap; }
.kpi-camps b { font-weight: 600; color: var(--ink-2); }

.kpi-trial { color: #ff9046; }
.kpi-trial .kpi-ico { background: #fff2e8; }
.kpi-formal { color: #4e8af4; }
.kpi-formal .kpi-ico { background: #eaf1ff; }
.kpi-renew { color: #8b77f0; }
.kpi-renew .kpi-ico { background: #f1edff; }
.kpi-deduct { color: #5ea8b8; }
.kpi-deduct .kpi-ico { background: #e9f6f8; }
.kpi-attend { color: #0eb87f; }
.kpi-attend .kpi-ico { background: #e6f8f1; }
.kpi-leave { color: #f0b433; }
.kpi-leave .kpi-ico { background: #fdf5e2; }
.kpi-absent { color: #f25555; }
.kpi-absent .kpi-ico { background: #feecec; }

.sec-title {
  font-size: 14px; font-weight: 650; color: var(--ink);
  margin: 22px 0 12px; display: flex; align-items: center; gap: 8px;
}
.sec-title::before {
  content: ''; width: 3px; height: 14px; border-radius: 2px;
  background: linear-gradient(180deg, #17cf8f, #069c6a);
}

.todo-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1300px) { .todo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .todo-grid { grid-template-columns: 1fr; } }

.todo-card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r);
  border-left: 3px solid #ff9046;
  padding: 13px 14px 10px;
  box-shadow: var(--shadow);
  cursor: pointer; transition: transform .18s, box-shadow .18s;
}
.todo-card:hover { transform: translateY(-2px); box-shadow: 0 2px 6px rgba(16,26,44,.05), 0 16px 30px -14px rgba(16,26,44,.2); }
.todo-card.clean { border-left-color: #d9e2ec; cursor: default; }
.todo-card.clean:hover { transform: none; }
.todo-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 9px; }
.todo-name { font-size: 13px; font-weight: 650; color: var(--ink); }
.todo-badge {
  font-size: 11px; padding: 1px 8px; border-radius: 999px; font-weight: 600; white-space: nowrap;
}
.todo-badge.hot { background: #fff2e8; color: #e8730a; }
.todo-badge.ok { background: #eef2f7; color: #8b98a9; }
.todo-rows { display: flex; flex-direction: column; gap: 1px; }
.todo-row {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 5px 0; border-bottom: 1px dashed #f0f4f8;
}
.todo-row:last-child { border-bottom: 0; }
.tr-main { font-size: 12.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tr-sub { font-size: 11px; color: var(--ink-3); white-space: nowrap; flex: 0 0 auto; }
.todo-more { font-size: 11px; color: var(--ink-3); padding-top: 6px; }
.todo-empty { font-size: 12px; color: #b3c0ce; padding: 10px 0; text-align: center; }

/* 趋势图 */
.trend { display: flex; align-items: flex-end; gap: 6px; height: 130px; padding-top: 6px; }
.trend-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; }
.trend-bars { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 3px; width: 100%; }
.bar { width: 42%; max-width: 12px; border-radius: 3px 3px 0 0; min-height: 2px; transition: height .3s; }
.b-formal { background: linear-gradient(180deg, #4e8af4, #8fb6ff); }
.b-trial { background: linear-gradient(180deg, #0eb87f, #5fdcb1); }
.trend-x { font-size: 10px; color: var(--ink-3); white-space: nowrap; }

.line-row {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 0; border-bottom: 1px dashed #f0f4f8;
}
.line-row:last-child { border-bottom: 0; }
.lr-name { font-size: 13px; color: var(--ink); font-weight: 500; }
.lr-sub { font-size: 11.5px; color: var(--ink-3); margin-left: auto; }

.funnel-row { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; font-size: 12.5px; color: var(--ink-2); }
.funnel-row > span { width: 52px; flex: 0 0 52px; }
.funnel-row > b { width: 30px; text-align: right; color: var(--ink); font-variant-numeric: tabular-nums; }
.funnel-bar-wrap { flex: 1; height: 10px; background: #f2f5f9; border-radius: 6px; overflow: hidden; }
.funnel-bar { height: 100%; border-radius: 6px; transition: width .4s; }
.fb-1 { background: linear-gradient(90deg, #ffb27a, #ff9046); }
.fb-2 { background: linear-gradient(90deg, #8fb6ff, #4e8af4); }
.fb-3 { background: linear-gradient(90deg, #5fdcb1, #0eb87f); }

/* ============ 今日课次 ============ */
.day-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.day-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.dchip {
  font-size: 12px; color: var(--ink-2);
  background: var(--white); border: 1px solid var(--line);
  padding: 4px 11px; border-radius: 999px;
}
.dchip b { font-weight: 700; color: var(--ink); margin-left: 2px; }
.dchip.d-ok { background: #eafaf4; border-color: #c9f0e1; color: #0a8a5f; }
.dchip.d-ok b { color: #07865b; }
.dchip.d-leave { background: #fdf7e6; border-color: #f7e9c2; color: #a8802a; }
.dchip.d-leave b { color: #9a7420; }
.dchip.d-bad { background: #fdeeee; border-color: #f8d4d4; color: #c94545; }
.dchip.d-bad b { color: #bd3a3a; }
.dchip.d-warn { background: #fff4ea; border-color: #ffe0c9; color: #c4730f; }
.dchip.d-warn b { color: #b96a08; }

.day-split { display: grid; grid-template-columns: 296px minmax(0, 1fr); gap: 14px; align-items: start; }
@media (max-width: 1100px) { .day-split { grid-template-columns: 1fr; } }

.lesson-list { display: flex; flex-direction: column; gap: 9px; }
.lesson-item {
  background: var(--white); border: 1px solid var(--line); border-radius: 12px;
  padding: 11px 13px; cursor: pointer;
  border-left: 3px solid #e2e9f1;
  transition: border-color .16s, box-shadow .16s, transform .16s;
}
.lesson-item:hover { box-shadow: 0 12px 24px -16px rgba(16, 26, 44, .5); transform: translateY(-1px); }
.lesson-item.active { border-left-color: var(--primary); background: #f7fdfa; box-shadow: 0 12px 26px -16px rgba(14, 184, 127, .8); }
.lesson-item.done { opacity: .72; }
.li-time { display: flex; align-items: center; gap: 8px; }
.li-clock { font-size: 15px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.li-range { font-size: 11px; color: var(--ink-3); }
.li-camp {
  margin-left: auto; font-size: 10.5px; color: #4e8af4;
  background: #eef3ff; padding: 1px 7px; border-radius: 5px;
}
.li-name { font-size: 13.5px; font-weight: 600; color: var(--ink); margin: 6px 0 5px; }
.li-meta { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--ink-3); flex-wrap: wrap; }
.li-count { color: var(--ink-2); }

.mark-panel {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow); padding: 16px 18px;
}
.mp-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; }
.mp-title { font-size: 16px; font-weight: 700; color: var(--ink); }
.mp-sub { font-size: 11.5px; color: var(--ink-3); font-weight: 400; margin-top: 5px; }
.mp-btns { display: flex; gap: 7px; flex-wrap: wrap; }
.mark-table { margin-top: 4px; }
.att-row { display: flex; align-items: center; gap: 6px; }
.mp-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  margin-top: 14px; padding-top: 13px; border-top: 1px solid var(--line); flex-wrap: wrap;
}
.mp-foot .muted { max-width: 60%; line-height: 1.6; }

.mark-empty {
  background: var(--white); border: 1px dashed #d9e2ec; border-radius: var(--r);
  min-height: 420px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
}
.me-ico { width: 62px; height: 62px; border-radius: 20px; background: #f2f7f5; display: flex; align-items: center; justify-content: center; }
.me-ico svg { width: 28px; height: 28px; fill: none; stroke: #9dc9b9; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.me-text { font-size: 13px; color: var(--ink-3); }

/* ============ 弹窗内小元素 ============ */
.sched-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.stu-chips { display: flex; flex-wrap: wrap; gap: 8px; min-height: 34px; }
.stu-chip { margin: 0; }
.d-head { padding-bottom: 4px; }

/* ============ 窄屏 ============ */
@media (max-width: 860px) {
  .side { width: var(--side-w-mini); flex: 0 0 var(--side-w-mini); }
  .side .brand-text, .side .nav-item span, .side .nav-group, .side .side-foot { display: none; }
  .side .brand { padding: 0 16px; justify-content: center; }
  .side .nav-item { justify-content: center; padding: 0; }
  .page-title { font-size: 15px; }
  .user-name, .user-role, .tb-lbl { display: none; }
  .main { padding: 14px; }
  .login-brand { display: none; }
}
