:root {
  color-scheme: light;
  font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  --ink: #172b35;
  --muted: #526a74;
  --line: #dbe5e6;
  --surface: #ffffff;
  --canvas: #f2f6f7;
  --accent: #0f6b61;
  --accent-deep: #0b564e;
  --accent-soft: #e3f2ef;
  color: var(--ink);
  background: var(--canvas);
  line-height: 1.55;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--accent-deep); text-underline-offset: .18em; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
img { max-width: 100%; }
.site-header { color: var(--ink); background: var(--surface); border-bottom: 1px solid var(--line); }
.header-inner {
  padding-inline: clamp(14px, 2vw, 30px);
}
.header-inner { min-height: 65px; display: flex; gap: 12px; justify-content: space-between; align-items: center; }
.header-start { display: flex; gap: 14px; align-items: center; }
.brand { display: flex; gap: 10px; align-items: center; color: var(--ink); text-decoration: none; white-space: nowrap; font-size: 18px; font-weight: 720; line-height: 1.2; }
.brand img { display: block; width: 37px; height: 37px; }
.brand-name { display: block; max-width: min(30vw, 28ch); overflow: hidden; text-overflow: ellipsis; }
.brand-note { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; font-weight: 400; }
.user-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; font-size: 13px; }
.user-actions form { margin: 0; }
.user-action-link {
  display: block; padding: 7px; border: 0; border-radius: 6px; background: transparent;
  white-space: nowrap; color: var(--muted); text-decoration: none;
}
.user-action-link:hover { color: var(--accent-deep); background: var(--accent-soft); }
.user-profile {
  display: flex; align-items: center; gap: 9px; margin-left: 7px; padding: 3px 3px 3px 10px;
  border-radius: 999px; color: var(--ink); text-decoration: none;
}
.user-profile:hover { background: var(--accent-soft); }
.user-name { max-width: 13ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-avatar {
  display: grid; place-items: center; width: 36px; height: 36px; overflow: hidden;
  border-radius: 50%; background: var(--accent-soft); color: var(--accent-deep); font-size: 15px; font-weight: 700;
}
.user-avatar img { width: 100%; height: 100%; object-fit: cover; }
.qd-menu-toggle { display: none; }
.qd-shell-with-nav { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; }
.qd-sidebar {
  position: sticky;
  top: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  min-height: calc(100dvh - 66px);
  max-height: 100dvh;
  overflow-y: auto;
  border-right: 1px solid var(--line);
  background: var(--surface);
}
.qd-nav-rail {
  width: 126px;
  padding: 16px 8px;
  background: #eaf2f2;
}
.qd-nav-panels { width: 156px; padding: 16px 10px; }
.qd-nav-panel:not([hidden]) + .qd-nav-panel:not([hidden]) { margin-top: 8px; }
.qd-nav-rail :is(a, button), .qd-nav-panel a {
  display: flex;
  align-items: center;
  gap: 7px;
  width: 100%;
  min-height: 42px;
  padding: 8px 9px;
  border: 0;
  border-radius: 8px;
  color: #2e4a53;
  background: transparent;
  text-decoration: none;
  text-align: left;
  font-size: 14px;
}
.qd-nav-rail :is(a, button) { font-weight: 650; }
.qd-nav-rail button[hidden] { display: none; }
.qd-nav-rail button::after {
  content: "";
  flex: 0 0 6px;
  height: 6px;
  margin-left: auto;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(-45deg);
}
.qd-nav-rail button[aria-expanded="true"]::after { transform: rotate(45deg); }
.qd-sidebar :is(a, button):hover { background: #dcecea; }
:is(a, button, summary):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.qd-sidebar a[aria-current], .qd-nav-rail button[aria-expanded="true"] { color: var(--accent-deep); background: #d5ebe7; }
.qd-sidebar a[aria-current] { box-shadow: inset 3px 0 var(--accent); font-weight: 700; }
.main-content { width: 100%; min-width: 0; max-width: 1600px; margin: 0 auto; padding: 28px clamp(14px, 2.5vw, 36px) 44px; }
.skip-link { position: absolute; top: -100px; left: 12px; background: white; padding: 8px; z-index: 10; }
.skip-link:focus { top: 8px; }
.signin-card, .qd-panel, .error-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px clamp(16px, 3vw, 30px); margin-bottom: 16px; }
.signin-card { width: min(100%, 440px); margin: clamp(24px, 8vh, 90px) auto; padding-block: 30px; }
.signin-card h1, .qd-panel h1 { font-size: clamp(23px, 3vw, 29px); margin: 8px 0; line-height: 1.25; }
.signin-card p, .qd-panel p { color: var(--muted); }
.signin-card label { display: block; font-weight: 650; margin: 14px 0 4px; }
.signin-card input:not([type=hidden]), .account-row input, .account-row select {
  border: 1px solid #bacbcc;
  border-radius: 8px;
  min-height: 42px;
  padding: 7px 10px;
  color: inherit;
  background: var(--surface);
}
.signin-card input:not([type=hidden]) { display: block; width: 100%; }
.signin-card .qd-primary { display: block; margin-top: 20px; width: 100%; }
.qd-primary { color: white; font-weight: 650; background: var(--accent); border: 1px solid var(--accent); border-radius: 8px; padding: 10px 15px; }
.qd-primary:hover { background: var(--accent-deep); }
.form-errors { color: #a02d2c; }
.form-errors.validation-summary-valid { display: none; }
:is(input, textarea, select):focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.qd-notice { background: var(--accent-soft); border: 1px solid #bfdcd1; padding: 13px; border-radius: 8px; }
.qd-notice code { font-size: 1.2em; user-select: all; color: var(--ink); }
.qd-table-scroll { overflow-x: auto; }
.qd-table { width: 100%; border-collapse: collapse; }
.qd-table :is(th, td) { border-bottom: 1px solid var(--line); text-align: left; padding: 10px; }
.qd-table th { color: var(--muted); background: #eff5f5; font-size: .88rem; }
.account-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.account-row button { border: 1px solid #9ebbb6; border-radius: 6px; padding: 6px 9px; background: #f1f8f6; color: #19514b; }
@media screen and (max-width: 860px) {
  .qd-shell-with-nav { display: block; }
  .qd-sidebar {
    position: static;
    min-height: 0;
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .qd-sidebar[data-mobile-open="false"] { display: none; }
  .qd-nav-panels { width: auto; }
  .qd-menu-toggle:not([hidden]) {
    display: block;
    flex: none;
    min-height: 38px;
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--accent-deep);
    background: var(--accent-soft);
    font-size: 13px;
  }
}
@media (max-width: 620px) {
  .header-inner { min-height: 60px; }
  .header-inner, .header-start, .brand { gap: 6px; }
  .brand { font-size: 15px; }
  .brand img, .user-avatar { width: 31px; height: 31px; }
  .user-actions { gap: 2px; }
  .user-action-link { padding-inline: 4px; }
  .user-profile { margin-left: 2px; padding: 2px; }
  .user-name { display: none; }
  .main-content { padding-top: 20px; }
}
@media (max-width: 355px) {
  .brand img { display: none; }
}
@media print {
  .site-header, .qd-sidebar, .skip-link { display: none !important; }
  .qd-shell-with-nav { display: block; }
  .main-content { margin: 0; padding: 0; max-width: none; }
  :root { background: white; }
}
