:root {
  --ink: #13262f;
  --muted: #687984;
  --line: #d8e2e5;
  --surface: #ffffff;
  --canvas: #f4f7f6;
  --green: #1f7466;
  --green-dark: #14574d;
  --blue: #315e88;
  --orange: #d97937;
  --red: #b6463b;
  --yellow-soft: #fff4d6;
  --shadow: 0 10px 28px rgba(28, 49, 57, .08);
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  color: var(--ink);
}
* { box-sizing: border-box; }
html { min-width: 320px; background: var(--canvas); }
body { margin: 0; background: var(--canvas); color: var(--ink); font-size: 15px; letter-spacing: 0; }
a { color: var(--green-dark); text-decoration: none; }
button, input, select { font: inherit; letter-spacing: 0; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .5; }
.topbar { min-height: 76px; padding: 12px clamp(18px, 4vw, 58px); display: flex; align-items: center; gap: 28px; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--ink); white-space: nowrap; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--green), var(--blue)); border-radius: 6px; font-size: 21px; font-weight: 800; }
.brand strong, .brand small { display: block; }.brand strong { font-size: 17px; }.brand small { margin-top: 2px; color: var(--muted); font-size: 12px; }
.main-nav { display: flex; gap: 4px; margin-left: auto; }
.main-nav a { padding: 10px 14px; color: #42535d; border-bottom: 3px solid transparent; font-weight: 700; }
.main-nav a:hover, .main-nav a.active { color: var(--green-dark); border-bottom-color: var(--green); }
.account { display: flex; align-items: center; gap: 12px; padding-left: 18px; border-left: 1px solid var(--line); }
.account-link { color: var(--ink); font-weight: 700; white-space: nowrap; }.account-link small { display: block; color: var(--muted); font-size: 11px; font-weight: 500; }
.account form { margin: 0; }
.page-shell { width: min(1460px, calc(100% - 36px)); margin: 28px auto 60px; }
.page-heading { display: flex; justify-content: space-between; align-items: end; gap: 20px; padding: 22px 0 25px; border-bottom: 2px solid var(--ink); }
.page-heading h1 { margin: 5px 0 5px; font-size: 32px; line-height: 1.25; }.page-heading p { margin: 0; color: var(--muted); }
.eyebrow { color: var(--green); font-size: 12px; font-weight: 800; text-transform: uppercase; }
.button { min-height: 40px; display: inline-flex; align-items: center; justify-content: center; padding: 8px 15px; border: 1px solid #bfcdd1; border-radius: 5px; background: #fff; color: var(--ink); font-weight: 700; }
.button:hover { border-color: var(--green); color: var(--green-dark); }.button.primary { background: var(--green); border-color: var(--green); color: #fff; }.button.primary:hover { background: var(--green-dark); }.button.ghost { background: transparent; }.button.compact { min-height: 34px; padding: 5px 10px; font-size: 13px; }.button.wide { width: 100%; }
.alert { margin-bottom: 16px; padding: 12px 15px; border-left: 4px solid var(--green); background: #e7f3ef; }.alert.error { border-color: var(--red); background: #fbe9e6; }.alert.warning { border-color: var(--orange); background: var(--yellow-soft); }
.metric-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 22px 0; border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow); }
.metric-strip div { padding: 20px 25px; border-right: 1px solid var(--line); }.metric-strip div:last-child { border-right: 0; }.metric-strip strong { display: block; font-size: 30px; }.metric-strip span { color: var(--muted); }
.content-section { margin-top: 22px; padding: 22px; background: var(--surface); border-top: 4px solid var(--green); box-shadow: var(--shadow); }.content-section.no-top-border { border-top-width: 1px; }
.section-heading { min-height: 40px; display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-bottom: 16px; }.section-heading h2 { margin: 0; font-size: 21px; }.section-heading span { color: var(--muted); }
.class-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.class-item { min-width: 0; padding: 17px; border: 1px solid var(--line); border-left: 4px solid var(--blue); border-radius: 5px; }.class-item h3 { margin: 15px 0 6px; font-size: 18px; }.class-item p { margin: 0 0 17px; color: var(--muted); }.class-meta, .class-footer { display: flex; justify-content: space-between; align-items: center; gap: 10px; }.class-footer { padding-top: 13px; border-top: 1px solid var(--line); }
.tag, .status { display: inline-flex; align-items: center; min-height: 27px; padding: 3px 9px; border-radius: 4px; background: #edf2f3; font-size: 12px; font-weight: 700; }.tag.category-机器人 { background: #e4f2ee; color: #116353; }.tag.category-航模 { background: #e8eff8; color: #315e88; }.tag.category-无人机 { background: #fff0e4; color: #a55723; }.tag.category-电子百拼 { background: #f0e8f5; color: #704a82; }
.status.success, .payment-paid { background: #dff1e9; color: #126448; }.status.warning, .payment-pending, .payment-partial { background: #fff0cc; color: #835b00; }.status.danger, .payment-refunded, .payment-void { background: #f9dfdc; color: #972f28; }
.empty-state { padding: 40px 20px; text-align: center; border: 1px dashed #b9c7cb; }.empty-state strong { font-size: 18px; }.empty-state p { color: var(--muted); }
.filter-band, .date-switch { display: flex; align-items: end; gap: 12px; margin: 22px 0; padding: 17px; background: #eaf1f0; border: 1px solid #d1dedd; }
label { display: grid; gap: 7px; color: #34474f; font-size: 13px; font-weight: 700; }
input, select { width: 100%; min-height: 42px; padding: 8px 11px; border: 1px solid #c8d4d8; border-radius: 4px; background: #fff; color: var(--ink); }
input:focus, select:focus { outline: 3px solid rgba(31, 116, 102, .15); border-color: var(--green); }
.filter-band label { min-width: 220px; flex: 1; }.date-switch label { width: 230px; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 720px; }
th, td { padding: 13px 11px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }th { color: #4d6069; background: #f1f5f4; font-size: 13px; }td small { display: block; margin-top: 4px; color: var(--muted); }.table-empty { padding: 32px; color: var(--muted); text-align: center; }
.action-row, .action-row form, .row-form, .inline-form { display: flex; align-items: end; gap: 8px; }.action-row { flex-wrap: wrap; }.action-row form { margin: 0; }.action-row select, .row-form select { width: auto; min-height: 34px; padding: 5px 8px; }.row-form input { min-width: 130px; min-height: 34px; padding: 5px 8px; }
.muted { color: var(--muted); }.text-danger { padding: 4px; border: 0; background: transparent; color: var(--red); font-weight: 700; }
.form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: end; }.form-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }.class-create-form { grid-template-columns: 1.1fr 1.5fr .8fr 1fr .8fr .8fr auto; }.student-create-form { grid-template-columns: 1fr 1.2fr 1fr 1.7fr auto; }.student-in-class-form { grid-template-columns: minmax(220px, 1fr) minmax(220px, 1fr) auto; }.payment-form { grid-template-columns: 1.7fr .8fr 1fr 1.7fr auto; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.segmented { display: inline-grid; grid-template-columns: repeat(3, 74px); border: 1px solid #bfccd0; border-radius: 4px; overflow: hidden; }.segmented label { display: block; }.segmented input { position: absolute; opacity: 0; pointer-events: none; }.segmented span { height: 38px; display: grid; place-items: center; background: #fff; border-right: 1px solid #d4dcdf; cursor: pointer; }.segmented label:last-child span { border-right: 0; }.segmented input:checked + span { background: var(--green); color: #fff; }
.credential-output { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px; margin-bottom: 15px; padding: 16px; background: #eef5ff; border: 1px solid #b7cee7; }.credential-output strong { font-size: 24px; color: var(--blue); letter-spacing: 0; }.credential-output small { color: var(--muted); }
.inline-form { margin-bottom: 16px; }.inline-form label { width: 180px; }.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }.compact-table { max-height: 330px; }.auth-shell { min-height: calc(100vh - 130px); display: grid; place-items: center; }
.auth-panel { width: min(450px, 100%); padding: 34px; background: #fff; border-top: 5px solid var(--green); box-shadow: 0 20px 55px rgba(25, 48, 58, .14); }.register-panel { width: min(520px, 100%); }.auth-heading { margin-bottom: 25px; }.auth-heading h1 { margin: 7px 0; font-size: 29px; }.auth-heading p, .auth-link { color: var(--muted); }.stack-form { display: grid; gap: 15px; }.auth-link { margin: 20px 0 0; text-align: center; }
.attendance-heading { align-items: center; }.attendance-form { border-top-color: var(--blue); }.finance-metrics strong { font-size: 25px; }.account-panel { width: min(620px, 100%); }.account-panel .form-actions { justify-content: flex-start; }
.account-summary { display: grid; gap: 6px; padding: 14px 16px; background: #f4f7f6; border-left: 4px solid var(--green); }.account-summary span, .account-summary small, .section-note { color: var(--muted); }.account-summary strong { font-size: 20px; }.section-note { margin: -4px 0 14px; }.account-table { min-width: 1080px; }.account-table .table-input { min-width: 145px; min-height: 36px; padding: 6px 8px; }.account-table .password-input { min-width: 155px; }
@media (max-width: 1050px) {
  .topbar { flex-wrap: wrap; gap: 10px; }.main-nav { order: 3; width: 100%; overflow-x: auto; }.account { margin-left: auto; }.class-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.form-grid, .class-create-form, .student-create-form, .student-in-class-form, .payment-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }.filter-band { flex-wrap: wrap; }.filter-band label { min-width: 190px; }
}
@media (max-width: 680px) {
  .topbar { padding: 10px 14px; position: static; }.brand small { display: none; }.account-link { display: none; }.main-nav a { flex: 0 0 auto; padding: 9px 12px; }.page-shell { width: min(100% - 20px, 1460px); margin-top: 14px; }.page-heading { align-items: flex-start; flex-direction: column; }.page-heading h1 { font-size: 26px; }.metric-strip, .class-grid, .form-grid, .form-grid.two, .class-create-form, .student-create-form, .student-in-class-form, .payment-form { grid-template-columns: 1fr; }.metric-strip div { border-right: 0; border-bottom: 1px solid var(--line); }.metric-strip div:last-child { border-bottom: 0; }.content-section { padding: 15px; }.filter-band, .date-switch { align-items: stretch; flex-direction: column; }.filter-band label, .date-switch label { width: 100%; min-width: 0; }.credential-output { grid-template-columns: 1fr; }.credential-output strong { overflow-wrap: anywhere; }.segmented { grid-template-columns: repeat(3, minmax(64px, 1fr)); }.auth-panel { padding: 25px 20px; }.inline-form, .row-form { flex-wrap: wrap; align-items: stretch; }.inline-form label { width: 100%; }
  .class-table { min-width: 0; }.class-table thead { display: none; }.class-table tbody, .class-table tr, .class-table td { display: block; width: 100%; }.class-table tr { margin-bottom: 12px; padding: 13px; border: 1px solid var(--line); border-left: 4px solid var(--green); }.class-table td { padding: 5px 0; border: 0; }.class-table td:first-child { padding-bottom: 9px; border-bottom: 1px solid var(--line); }.class-table td:nth-child(2)::before { content: "上课："; color: var(--muted); }.class-table td:nth-child(3)::before { content: "教师："; color: var(--muted); }.class-table td:nth-child(4)::before { content: "学生："; color: var(--muted); }.class-table td:nth-child(5)::before { content: "关系："; color: var(--muted); }.class-table td:last-child { padding-top: 10px; }.class-table .action-row { align-items: stretch; flex-direction: column; }.class-table .action-row form { align-items: stretch; flex-direction: column; }.class-table .action-row select { width: 100%; }
  .attendance-form table { min-width: 0; }.attendance-form thead { display: none; }.attendance-form tbody, .attendance-form tr, .attendance-form td { display: block; width: 100%; }.attendance-form tr { padding: 13px 0; border-bottom: 1px solid var(--line); }.attendance-form td { padding: 5px 0; border: 0; }.attendance-form td:first-child { padding-bottom: 9px; }.attendance-form .segmented { width: 100%; }.attendance-form td input { width: 100%; }
  .student-list-table { min-width: 0; }.student-list-table thead { display: none; }.student-list-table tbody, .student-list-table tr, .student-list-table td { display: block; width: 100%; }.student-list-table tr { padding: 10px 0; border-bottom: 1px solid var(--line); }.student-list-table td { display: grid; grid-template-columns: 84px minmax(0, 1fr); align-items: center; gap: 8px; padding: 6px 0; border: 0; }.student-list-table td::before { content: attr(data-label); color: var(--muted); font-size: 12px; font-weight: 700; }.student-list-table td form, .student-list-table td .button { width: 100%; }
  .account-table-editable { min-width: 0; }.account-table-editable thead { display: none; }.account-table-editable tbody, .account-table-editable tr, .account-table-editable td { display: block; width: 100%; }.account-table-editable tr { margin-bottom: 13px; padding: 13px; border: 1px solid var(--line); border-left: 4px solid var(--green); }.account-table-editable td { display: grid; grid-template-columns: 88px minmax(0, 1fr); align-items: center; gap: 8px; padding: 6px 0; border: 0; }.account-table-editable td::before { color: var(--muted); font-size: 12px; font-weight: 700; }.account-table-editable td:nth-child(1)::before { content: "姓名"; }.account-table-editable td:nth-child(2)::before { content: "登录账号"; }.account-table-editable td:nth-child(3)::before { content: "重置密码"; }.account-table-editable td:nth-child(4)::before { content: "角色"; }.account-table-editable td:nth-child(5)::before { content: "状态"; }.account-table-editable td:nth-child(6)::before { content: "创建时间"; }.account-table-editable td:nth-child(7)::before { content: "操作"; }.account-table-editable .table-input { min-width: 0; width: 100%; }.account-table-editable td:last-child form, .account-table-editable td:last-child button { width: 100%; }
}
