/* 中文业务界面：颜色变量集中维护；移动端表格只在容器内滚动。 */
:root {
  --ink:#17324d;
  --muted:#58697b;
  --border:#dee6ee;
  --surface:#fff;
  --canvas:#f4f7fa;
  --primary:#245b85;
  --danger:#b02a37;
  --warning:#885600;
  --radius:10px;
  --line:var(--border);
  --accent:var(--primary);
}
* {
  box-sizing:border-box;
}
body {
  font-family:system-ui,-apple-system,"Segoe UI","Microsoft YaHei",sans-serif;
  color:var(--ink);
  background:var(--canvas);
  font-size:16px;
  line-height:1.6;
}
a {
  color:#205d91;
  text-underline-offset:3px;
}
a:hover {
  color:#143d61;
}
h1 {
  font-size:clamp(1.5rem,2vw,2rem);
  font-weight:700;
  line-height:1.35;
  overflow-wrap:anywhere;
  margin:0;
}
h2 {
  font-size:1.12rem;
  font-weight:700;
  margin:0 0 20px;
}
h3 {
  font-size:1rem;
  font-weight:650;
  margin:16px 0 10px;
}
.btn {
  min-height:44px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  font-weight:600;
  border-radius:7px;
  padding:9px 16px;
  white-space:normal;
  transition:background-color .15s,color .15s;
}
.btn-primary {
  --bs-btn-bg:var(--primary);
  --bs-btn-border-color:var(--primary);
  --bs-btn-hover-bg:#173f60;
  --bs-btn-hover-border-color:#173f60;
}
.btn-outline-primary {
  --bs-btn-color:var(--primary);
  --bs-btn-border-color:var(--primary);
  --bs-btn-hover-bg:var(--primary);
  --bs-btn-hover-border-color:var(--primary);
}
.btn-outline-secondary {
  --bs-btn-color:#4d5c6b;
  --bs-btn-border-color:#a8b4c0;
}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible {
  outline:3px solid #287ab4!important;
  outline-offset:3px;
}
.form-control,.form-select {
  min-height:44px;
  font-size:1rem;
}
.form-control:focus,.form-select:focus {
  border-color:#287ab4;
  box-shadow:0 0 0 .2rem #287ab422;
}
.form-label {
  font-weight:600;
  font-size:.9rem;
}
.form-text,.text-muted,.cell-secondary {
  color:var(--muted)!important;
}
.text-muted,.cell-secondary {
  font-size:.875rem;
}
.form-check {
  display:flex;
  gap:10px;
  align-items:flex-start;
  padding:0;
}
.form-check-input {
  position:relative;
  float:none!important;
  flex-shrink:0;
  margin:6px 0 0!important;
  width:20px;
  height:20px;
}
.form-check-label {
  min-height:44px;
  padding-top:2px;
}
.required,.field-error {
  color:var(--danger);
}
.field-error {
  font-size:.9rem;
  margin-top:6px;
}
.field-error ul,.errorlist {
  padding-left:1.25rem;
  margin:0;
}
.skip-link {
  position:fixed;
  top:-80px;
  left:16px;
  z-index:200;
  background:white;
  padding:12px;
}
.skip-link:focus {
  top:10px;
}
.topbar {
  height:76px;
  padding:0 28px;
  background:var(--ink);
  color:white;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  position:sticky;
  top:0;
  z-index:100;
}
.brand {
  font-size:1.18rem;
  font-weight:750;
  color:white;
  text-decoration:none;
  display:flex;
  align-items:center;
  gap:10px;
  white-space:nowrap;
}
.brand:hover {
  color:#ddecfa;
}
.brand-mark {
  width:36px;
  height:36px;
  border:1px solid #adc5db;
  border-radius:7px;
  display:grid;
  place-items:center;
}
.brand-sub {
  font-size:.8rem;
  font-weight:400;
  opacity:.78;
  margin-left:14px;
}
.account-menu {
  display:flex;
  gap:20px;
  align-items:center;
  font-size:.875rem;
}
.account-menu a {
  color:#fff;
}
.account-menu form {
  margin:0;
}
.account-name {
  min-width:0;
  overflow-wrap:anywhere;
}
.mobile-menu {
  display:none;
}
.app-shell {
  display:grid;
  grid-template-columns:224px minmax(0,1fr);
}
.sidebar {
  padding:30px 20px;
  background:#fff;
  border-right:1px solid var(--border);
  min-height:calc(100vh - 76px);
}
.nav-caption {
  font-size:.75rem;
  color:var(--muted);
  letter-spacing:.04em;
  margin:0 12px 12px;
}
.sidebar nav a {
  min-height:46px;
  display:flex;
  align-items:center;
  padding:10px 14px;
  text-decoration:none;
  color:#33495e;
  font-size:.93rem;
  font-weight:550;
  border-radius:7px;
  margin-bottom:5px;
}
.sidebar nav a:hover {
  background:#f0f5fa;
}
.sidebar nav a[aria-current=page] {
  background:#e9f1f9;
  color:var(--primary);
  font-weight:750;
}
.sidebar nav .nav-caption {
  margin-top:28px;
}
.sidebar-note {
  font-size:.8rem;
  color:var(--muted);
  border-top:1px solid var(--border);
  padding:20px 12px;
  line-height:1.8;
  margin-top:28px;
}
.main-content {
  padding:30px 32px;
  max-width:1800px;
  width:100%;
  min-width:0;
  outline:none;
}
.page-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:24px;
  margin:0 0 26px;
  flex-wrap:wrap;
}
.eyebrow {
  font-size:.75rem;
  letter-spacing:.13em;
  color:var(--muted);
  font-weight:700;
  margin:0 0 7px;
}
.action-group {
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
}
.panel {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:24px;
  min-width:0;
}
.form-panel {
  max-width:780px;
}
.form-intro {
  border-bottom:1px solid var(--border);
  padding-bottom:20px;
  margin-bottom:24px;
  color:var(--muted);
}
.form-actions {
  display:flex;
  gap:12px;
  border-top:1px solid var(--border);
  padding-top:24px;
  margin-top:24px;
  flex-wrap:wrap;
}
.filters {
  display:flex;
  gap:16px;
  align-items:flex-end;
  flex-wrap:wrap;
}
.filters>div {
  flex:1 1 150px;
  min-width:145px;
}
.filters>.filter-wide {
  flex:2 1 280px;
}
.filters>.filter-buttons {
  display:flex;
  gap:10px;
  flex:0 1 auto;
}
.filter-help {
  font-size:.84rem;
  color:var(--muted);
  margin:18px 0 0;
}
.section-heading {
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:center;
  margin-bottom:20px;
  flex-wrap:wrap;
}
.section-heading h2 {
  margin:0;
}
.reminder-row {
  display:flex;
  gap:14px;
  align-items:flex-start;
  padding:16px 0;
  border-bottom:1px solid var(--border);
}
.reminder-row:last-child {
  border:0;
}
.reminder-label {
  background:#fff3d9;
  color:#805400;
  border-radius:5px;
  padding:5px 9px;
  font-size:.78rem;
  white-space:nowrap;
  margin-top:2px;
}
.task-row {
  padding:12px 0;
  border-bottom:1px solid var(--border);
}
.task-row p {
  margin:4px 0 0;
}
.table-responsive {
  max-width:100%;
  border-radius:5px;
}
.table {
  font-size:.875rem;
  margin:0;
  --bs-table-border-color:var(--border);
}
.table th {
  background:#f6f8fb;
  color:#596b7d;
  font-size:.75rem;
  font-weight:650;
  padding:13px 14px;
  white-space:nowrap;
}
.table td {
  padding:16px 14px;
  max-width:340px;
  min-width:90px;
  vertical-align:middle;
}
.project-link {
  display:block;
  max-width:290px;
  min-width:180px;
  font-weight:650;
  overflow-wrap:anywhere;
}
.cell-secondary {
  margin-top:4px;
}
.money {
  text-align:right!important;
  font-variant-numeric:tabular-nums;
  white-space:nowrap;
}
.status,.settlement {
  display:inline-block;
  font-size:.75rem;
  border-radius:5px;
  padding:4px 8px;
  white-space:nowrap;
  background:#eef2f6;
  color:#475f74;
}
.status-drafting {
  background:#eaf1fb;
  color:#22537c;
}
.status-opening {
  background:#fff0d8;
  color:#855400;
}
.status-won,.settlement-paid {
  background:#e6f3ed;
  color:#236947;
}
.status-invalid,.status-withdrawn {
  background:#f6e8e8;
  color:#883638;
}
.settlement-unpaid,.settlement-partial {
  background:#fff1dc;
  color:#855400;
}
.empty-state {
  padding:30px 10px;
  text-align:center;
  color:var(--muted);
  font-size:.9rem;
}
.pagination-bar {
  display:flex;
  gap:16px;
  justify-content:center;
  align-items:center;
  flex-wrap:wrap;
  margin-top:24px;
  font-size:.875rem;
}
.search-bar {
  display:flex;
  gap:12px;
  margin-bottom:24px;
  align-items:center;
}
.search-bar input {
  max-width:500px;
}
.query-toolbar>.form-control { flex:1 1 220px; min-width:0; }
.query-actions,.filters>.query-actions { display:flex; flex:0 0 auto; flex-wrap:nowrap; gap:10px; min-width:0; }
.query-actions>.btn { flex:0 0 auto; white-space:nowrap; }
@media(max-width:767px) {
  .query-toolbar>.form-control { flex-basis:100%; max-width:none; }
  .query-toolbar>.query-actions,.filters>.query-actions { flex-basis:100%; }
  .query-toolbar .query-actions>.btn,.filters>.query-actions>.btn { flex:1 1 0; }
}
.detail-grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(210px,1fr));
  gap:22px 30px;
  margin:20px 0 26px;
}
.detail-grid dt {
  font-weight:500;
  color:var(--muted);
  font-size:.8rem;
  margin-bottom:6px;
}
.detail-grid dd {
  margin:0;
  overflow-wrap:anywhere;
}
.plain-note {
  white-space:pre-wrap;
  overflow-wrap:anywhere;
  background:#f7f9fb;
  border-radius:6px;
  padding:16px;
  color:#435668;
}
.financial-grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(145px,1fr));
  gap:16px;
  background:#f6f8fb;
  padding:20px;
  border-radius:7px;
}
.financial-grid span {
  display:block;
  color:var(--muted);
  font-size:.8rem;
}
.financial-grid strong {
  font-size:1.4rem;
  font-variant-numeric:tabular-nums;
  overflow-wrap:anywhere;
}
.file-row {
  display:flex;
  justify-content:space-between;
  gap:16px;
  padding:18px 0;
  border-bottom:1px solid var(--border);
  align-items:flex-start;
}
.file-row>div {
  min-width:0;
  overflow-wrap:anywhere;
}
.digest {
  display:block;
  white-space:normal;
  overflow-wrap:anywhere;
  font-size:.75rem;
  margin-top:8px;
}
.evidence-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:16px;
}
.evidence-card {
  border:1px solid var(--border);
  border-radius:7px;
  padding:18px;
  overflow-wrap:anywhere;
}
.evidence-card blockquote {
  border-left:3px solid #b7cbdc;
  padding-left:14px;
  margin:10px 0;
  font-size:.9rem;
  color:#536576;
}
.evidence-data {
  white-space:pre-wrap;
  word-break:break-word;
  font-size:.82rem;
  background:#f7f9fb;
  padding:16px;
  margin:12px 0 0;
}
.evidence {
  padding:14px 0;
  border-bottom:1px solid var(--border);
}
.danger-zone {
  padding:28px 0;
}
.wrap-cell {
  white-space:pre-wrap;
  overflow-wrap:anywhere;
}
.receipt-total {
  padding:20px 0;
  font-size:1rem;
}
.receipt-total strong {
  font-size:1.5rem;
}
.app-footer {
  font-size:.75rem;
  color:#768696;
  margin-top:40px;
}
.login-shell {
  min-height:100vh;
  display:grid;
  place-items:center;
  padding:24px;
}
.login-card {
  width:min(100%,430px);
  border:1px solid var(--border);
  background:white;
  border-radius:12px;
  padding:36px;
}
.login-card h1 {
  font-size:1.45rem;
  margin-bottom:12px;
}
.login-logo {
  width:48px;
  height:48px;
  background:var(--ink);
  color:white;
  display:grid;
  place-items:center;
  border-radius:8px;
  font-size:1.3rem;
  margin-bottom:24px;
}
.login-footnote {
  font-size:.78rem;
  color:var(--muted);
  margin:24px 0 0;
}
.alert {
  overflow-wrap:anywhere;
}
.messages {
  margin-bottom:20px;
}
summary {
  cursor:pointer;
  min-height:36px;
}
button,a,input,select {
  touch-action:manipulation;
}
.error-summary a {
  color:#842029;
}
.form-control,.form-select,.error-summary {
  scroll-margin-top:150px;
}
@media(max-width:1000px) {
  .main-content {
    padding:24px;
  }
  .app-shell {
    grid-template-columns:190px minmax(0,1fr);
  }
  .brand-sub {
    display:none;
  }
  .sidebar {
    padding:24px 12px;
  }
}
@media(max-width:767px) {
  /* 手机筛选操作单独占满一行，避免剩余空间将中文按钮挤成竖排。 */
  .filters>.home-filter-actions {
    flex-basis:100%;
  }
  .home-filter-actions>.btn {
    flex:1;
    min-width:0;
    white-space:nowrap;
  }
  .topbar {
    height:auto;
    min-height:68px;
    padding:12px 16px;
    flex-wrap:wrap;
    gap:10px;
  }
  .mobile-menu {
    display:inline-flex;
    min-width:62px;
    padding:6px 10px;
  }
  .brand {
    font-size:1rem;
    flex:1;
  }
  .brand-mark {
    display:none;
  }
  .account-menu {
    flex-basis:100%;
    justify-content:flex-end;
    gap:18px;
    font-size:.8rem;
  }
  .account-name {
    margin-right:auto;
  }
  .account-menu .btn {
    padding:6px 12px;
    min-height:44px;
  }
  .app-shell {
    display:block;
  }
  .sidebar {
    display:none;
    min-height:0;
    border-bottom:1px solid var(--border);
    padding:16px;
  }
  .sidebar.is-open {
    display:block;
  }
  .sidebar-note {
    display:none;
  }
  .sidebar nav {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:6px;
  }
  .sidebar nav .nav-caption {
    grid-column:1/-1;
    margin:8px 12px;
  }
  .main-content {
    padding:22px 16px;
  }
  .page-heading {
    gap:16px;
    margin-bottom:20px;
  }
  .page-heading .action-group {
    width:100%;
  }
  .page-heading .action-group .btn {
    flex:1;
  }
  .panel {
    padding:18px;
  }
  .filters {
    gap:12px;
  }
  .filters>div {
    flex-basis:calc(50% - 12px);
    min-width:0;
  }
  .filters>.filter-wide {
    flex-basis:100%;
  }
  .filters>.filter-buttons {
    flex-basis:100%;
  }
  .filters>button,.filters>a {
    flex:1;
  }
  .financial-grid {
    padding:14px;
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .evidence-grid {
    grid-template-columns:1fr;
  }
  .search-bar {
    flex-wrap:wrap;
  }
  .search-bar input {
    flex-basis:100%;
  }
  .search-bar .btn {
    flex:1;
  }
  .table td,.table th {
    padding:12px 10px;
  }
  .login-card {
    padding:28px 24px;
  }
  .file-row {
    flex-wrap:wrap;
  }
  .detail-grid {
    grid-template-columns:1fr 1fr;
    gap:18px;
  }
  .detail-grid>div:first-child {
    grid-column:1/-1;
  }
  .reminder-row {
    gap:10px;
  }
  .pagination-bar {
    font-size:.8rem;
  }
  .section-heading {
    gap:10px;
  }
  .section-heading .text-muted {
    font-size:.75rem;
  }
  .form-actions .btn {
    flex:1;
  }
}
@media print {
  .sidebar,.topbar,.action-group,.danger-zone,.btn,.app-footer {
    display:none!important;
  }
  .app-shell {
    display:block;
  }
  .main-content {
    padding:0;
    max-width:none;
  }
  .panel {
    break-inside:avoid;
    border:1px solid #bbb;
  }
  .table-responsive {
    overflow:visible;
  }
  .table {
    font-size:9pt;
  }
  body {
    background:white;
    color:black;
  }
}
@media(prefers-reduced-motion:reduce) {
  *,*:before,*:after {
    transition:none!important;
    animation:none!important;
    scroll-behavior:auto!important;
  }
}

/* 登录后的导航采用浅磨砂皮肤；通用业务组件在文件末尾统一覆盖。 */
.app-glass {
  --ink:#243746;
  --muted:#536571;
  --primary:#137c90;
  --chart-track:#e2ecef;
  --border:#dce5e9;
  --glass:rgba(255,255,255,.8);
  --glass-border:rgba(255,255,255,.92);
  --glass-shadow:0 5px 22px rgba(37,65,78,.045);
  background:
    radial-gradient(ellipse at 2% 15%,rgba(131,193,204,.16),transparent 42%),
    radial-gradient(ellipse at 95% 65%,rgba(155,204,212,.12),transparent 45%),
    #f1f4f5;
}
.app-glass .topbar {
  height:68px;
  padding:0 24px;
  color:var(--ink);
  background:rgba(255,255,255,.76);
  border-bottom:1px solid rgba(218,229,233,.75);
  backdrop-filter:blur(18px);
  -webkit-backdrop-filter:blur(18px);
}
.app-glass .brand,.app-glass .brand:hover,.app-glass .account-menu a {
  color:var(--ink);
}
.app-glass .brand-mark {
  background:rgba(225,241,244,.9);
  border-color:#c6dfe4;
  color:#146d80;
  border-radius:10px;
}
.app-glass .brand-sub {
  opacity:1;
  color:var(--muted);
}
.app-glass .topbar .btn-outline-light {
  --bs-btn-color:#425967;
  --bs-btn-border-color:#b8c9d0;
  --bs-btn-hover-color:#194957;
  --bs-btn-hover-bg:#eaf3f5;
  --bs-btn-hover-border-color:#96bac4;
  --bs-btn-active-color:#194957;
  --bs-btn-active-bg:#e0eff2;
  --bs-btn-active-border-color:#96bac4;
}
.app-glass .app-shell {
  grid-template-columns:212px minmax(0,1fr);
  gap:24px;
  padding:24px;
  align-items:start;
}
.app-glass .sidebar {
  position:sticky;
  top:92px;
  min-height:0;
  max-height:calc(100vh - 116px);
  overflow-y:auto;
  padding:20px 12px 12px;
  background:rgba(255,255,255,.7);
  border:1px solid var(--glass-border);
  border-radius:18px;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(18px);
  -webkit-backdrop-filter:blur(18px);
}
.app-glass .sidebar nav a {
  border-radius:10px;
  margin-bottom:4px;
  color:#405562;
}
.app-glass .sidebar nav a:hover {
  background:rgba(226,239,242,.75);
}
.app-glass .sidebar nav a[aria-current=page] {
  background:#e0eff2;
  color:#126c7e;
  box-shadow:inset 3px 0 #218aa0;
}
.app-glass .sidebar-note {
  margin-top:20px;
  padding:16px 12px 8px;
}
.app-glass .main-content {
  padding:0;
}

/* 工作台以指标、图表、待办三层组织信息，与通用磨砂组件共用视觉变量。 */
.dashboard-home {
  display:grid;
  gap:20px;
  min-width:0;
}
.dashboard-home .panel,.dashboard-home .kpi-card {
  padding:20px;
  border:1px solid var(--glass-border);
  border-radius:18px;
  background:var(--glass);
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(16px);
  -webkit-backdrop-filter:blur(16px);
}
.dashboard-home .dashboard-toolbar {
  display:grid;
  grid-template-columns:172px minmax(0,1fr);
  gap:16px;
  align-items:center;
}
.dashboard-home .toolbar-title h2 {
  margin:0 0 4px;
  font-size:1rem;
}
.dashboard-home .toolbar-title strong,.dashboard-home .toolbar-title>span {
  display:block;
}
.dashboard-home .toolbar-title strong {
  font-size:1rem;
}
.dashboard-home .toolbar-title p {
  margin:0;
  color:var(--muted);
  font-size:.78rem;
}
.dashboard-home .filters {
  display:grid;
  grid-template-columns:minmax(116px,.8fr) repeat(2,minmax(145px,1fr)) auto;
  gap:12px;
  align-items:end;
}
.dashboard-home .filters>div {
  min-width:0;
}
.dashboard-home .filters .form-label {
  font-size:.78rem;
  margin-bottom:5px;
}
.dashboard-home .filters .form-control,.dashboard-home .filters .form-select {
  font-size:1rem;
  background-color:rgba(255,255,255,.88);
}
.dashboard-home .filters .filter-buttons {
  gap:8px;
}
.dashboard-home .filters .btn {
  padding:9px 12px;
  white-space:nowrap;
  font-size:.875rem;
}
.dashboard-home .filter-help {
  grid-column:1/-1;
  margin:0;
  font-size:.78rem;
}
.dashboard-kpis {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:16px;
}
.dashboard-home .kpi-card {
  min-width:0;
  padding:18px 20px;
}
.kpi-label {
  display:block;
  color:var(--muted);
  font-size:.85rem;
}
.kpi-value {
  display:block;
  margin:8px 0 7px;
  font-size:clamp(1.4rem,1.7vw,1.8rem);
  font-weight:700;
  line-height:1.25;
  letter-spacing:-.03em;
  font-variant-numeric:tabular-nums;
  overflow-wrap:anywhere;
}
.kpi-value em {
  margin-left:5px;
  font-size:.75rem;
  font-style:normal;
  font-weight:400;
  letter-spacing:0;
  color:var(--muted);
}
.kpi-note {
  display:block;
  color:var(--muted);
  font-size:.77rem;
  line-height:1.55;
  margin:0;
}
.dashboard-home .kpi-attention {
  border-color:#c9e1e6;
  background:rgba(240,250,251,.84);
}
.kpi-attention .kpi-value {
  color:#126c7e;
}
.dashboard-charts,.dashboard-tasks {
  display:grid;
  grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);
  gap:20px;
  align-items:stretch;
}
.dashboard-section-heading {
  display:flex;
  gap:12px;
  justify-content:space-between;
  align-items:center;
  margin-bottom:16px;
  flex-wrap:wrap;
}
.dashboard-section-heading h2 {
  margin:0;
  font-size:1rem;
}
.dashboard-section-heading .text-muted,.dashboard-section-heading>a {
  font-size:.78rem;
}
.status-chart {
  display:grid;
  gap:5px;
}
.status-bar-row {
  display:grid;
  grid-template-columns:72px minmax(0,1fr) 88px;
  gap:12px;
  min-height:44px;
  align-items:center;
  padding:5px 8px;
  margin:0 -8px;
  border-radius:8px;
  text-decoration:none;
  color:var(--ink);
}
.status-bar-row:hover {
  background:rgba(225,239,242,.6);
  color:var(--ink);
}
.status-bar-label {
  font-size:.85rem;
}
.status-bar-track {
  height:10px;
  overflow:hidden;
  background:#e7eef1;
  border-radius:999px;
}
.status-bar-fill {
  display:block;
  height:100%;
  background:var(--primary);
  border-radius:inherit;
}
.status-bar-value {
  text-align:right;
  font-weight:650;
  font-size:.85rem;
  font-variant-numeric:tabular-nums;
  line-height:1.25;
}
.status-bar-value small {
  display:block;
  font-size:.72rem;
  font-weight:400;
  color:var(--muted);
  line-height:1.25;
}
.chart-footnote {
  margin:14px 0 0;
  color:var(--muted);
  font-size:.78rem;
  line-height:1.6;
}
.collection-chart {
  display:flex;
  align-items:center;
  gap:24px;
  min-height:270px;
}
.collection-ring {
  width:184px;
  height:184px;
  border-radius:50%;
  flex:0 0 184px;
  display:grid;
  place-items:center;
  background:var(--chart-track);
}
.ring-center {
  width:calc(100% - 30px);
  height:calc(100% - 30px);
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  background:#f9fbfc;
  border:1px solid rgba(255,255,255,.9);
  border-radius:50%;
}
.ring-center strong {
  font-size:1.8rem;
  line-height:1.2;
  font-variant-numeric:tabular-nums;
  letter-spacing:-.03em;
}
.ring-center em {
  font-size:.55em;
  font-style:normal;
  margin-left:3px;
}
.ring-caption {
  margin-top:7px;
  color:var(--muted);
  font-size:.8rem;
}
.collection-legend {
  flex:1;
  min-width:0;
}
.collection-legend dl {
  display:block;
  margin:0;
  padding:12px 0;
  border-bottom:1px solid var(--border);
}
.collection-legend dl>div {
  display:grid;
  gap:3px;
  margin-bottom:16px;
}
.collection-legend dl>div:last-child {
  margin-bottom:0;
}
.collection-legend dl:last-child {
  border-bottom:0;
}
.collection-legend dt {
  color:var(--muted);
  font-weight:400;
  font-size:.82rem;
}
.collection-legend dd {
  margin:0;
  text-align:left;
  font-size:1.05rem;
  font-weight:650;
  font-variant-numeric:tabular-nums;
  overflow-wrap:anywhere;
}
.collection-legend dd small {
  margin-left:5px;
  font-size:.72rem;
  font-weight:400;
  color:var(--muted);
}
.collection-legend .legend-dot {
  display:inline-block;
  width:8px;
  height:8px;
  border-radius:50%;
  margin-right:7px;
  background:var(--primary);
}
.collection-legend .legend-dot.unreceived {
  background:#e0e9ed;
  border:1px solid #b8cbd3;
}
.dashboard-home .task-list {
  max-height:340px;
  overflow-y:auto;
  scrollbar-gutter:stable;
}
.dashboard-home .task-list:focus-visible {
  outline:2px solid var(--primary);
  outline-offset:3px;
}
.dashboard-home .reminder-row {
  padding:12px 0;
  gap:12px;
  font-size:.875rem;
}
.dashboard-home .reminder-row>div {
  min-width:0;
  overflow-wrap:anywhere;
}
.dashboard-home .reminder-row:first-child,.dashboard-home .task-row:first-child {
  padding-top:0;
}
.dashboard-home .reminder-label {
  padding:4px 8px;
  font-size:.75rem;
}
.dashboard-home .cell-secondary {
  font-size:.78rem;
}
.dashboard-home .task-row {
  padding:11px 0;
  font-size:.875rem;
}
.dashboard-home .empty-state {
  padding:32px 12px;
  font-size:.85rem;
}
.dashboard-home .recent-panel .table {
  --bs-table-bg:transparent;
}
.dashboard-home .recent-panel th {
  background:rgba(235,242,244,.65);
}
.dashboard-home .recent-panel th,.dashboard-home .recent-panel td {
  padding:12px;
}
.dashboard-home .recent-panel td {
  min-width:76px;
}
.dashboard-home .recent-panel .project-link {
  min-width:160px;
  max-width:340px;
}

/* 缩小布局时保留 44px 控件点击区域，日期与金额不挤成竖排。 */
@media(max-width:1199px) {
  .dashboard-home .dashboard-toolbar {
    grid-template-columns:1fr;
    gap:12px;
  }
  .dashboard-home .toolbar-title {
    display:flex;
    gap:12px;
    align-items:baseline;
    flex-wrap:wrap;
  }
  .dashboard-charts {
    grid-template-columns:1fr;
  }
  .collection-chart {
    min-height:200px;
    justify-content:center;
  }
  .collection-legend {
    flex:0 1 330px;
  }
}
@media(max-width:1000px) {
  .app-glass .app-shell {
    grid-template-columns:190px minmax(0,1fr);
    gap:20px;
    padding:20px;
  }
  .dashboard-kpis {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .dashboard-tasks {
    grid-template-columns:1fr;
  }
  .dashboard-home .filters {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .dashboard-home .filters .filter-buttons {
    align-self:end;
  }
  .dashboard-home .filters .filter-buttons .btn {
    flex:1;
  }
}
@media(max-width:767px) {
  .app-glass .topbar {
    height:auto;
    padding:12px 16px;
  }
  .app-glass .app-shell {
    display:block;
    padding:16px;
  }
  .app-glass .sidebar {
    position:static;
    max-height:none;
    margin-bottom:16px;
    padding:12px;
  }
  .dashboard-home {
    gap:16px;
  }
  .dashboard-home .panel {
    padding:16px;
    border-radius:16px;
  }
  .dashboard-home .kpi-card {
    padding:16px;
    border-radius:16px;
  }
  .dashboard-kpis {
    gap:12px;
  }
  .kpi-value {
    font-size:1.45rem;
  }
  .kpi-value em {
    display:inline;
  }
  .dashboard-home .filters {
    gap:12px;
  }
  .dashboard-home .filters>div:first-child {
    grid-column:1/-1;
  }
  .dashboard-home .filters .filter-buttons {
    grid-column:1/-1;
  }
  .dashboard-section-heading {
    gap:8px;
    margin-bottom:12px;
  }
  .collection-chart {
    gap:16px;
    min-height:172px;
  }
  .collection-ring {
    width:144px;
    height:144px;
    flex-basis:144px;
  }
  .ring-center {
    width:calc(100% - 24px);
    height:calc(100% - 24px);
  }
  .ring-center strong {
    font-size:1.5rem;
  }
  .collection-legend dl {
    grid-template-columns:1fr;
    gap:4px;
    padding:8px 0;
  }
  .collection-legend dd {
    text-align:left;
  }
  .status-bar-row {
    grid-template-columns:68px minmax(0,1fr) 64px;
    gap:10px;
  }
}

/* 用户明确选用应用内磨砂视觉；较高白色遮罩保证阅读，无模糊支持时降级为实色。 */
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
  .app-glass .topbar,.app-glass .sidebar,.dashboard-home .panel,.dashboard-home .kpi-card {
    background:#fbfcfd;
  }
}
@media print {
  .app-glass {
    background:white;
  }
  .app-glass .app-shell {
    display:block;
    padding:0;
  }
  .dashboard-home .panel,.dashboard-home .kpi-card {
    background:white;
    border-color:#bbb;
    box-shadow:none;
    backdrop-filter:none;
    -webkit-backdrop-filter:none;
    break-inside:avoid;
  }
  .dashboard-home .dashboard-toolbar {
    display:none;
  }
  .dashboard-kpis {
    grid-template-columns:repeat(4,minmax(0,1fr));
  }
  .dashboard-charts,.dashboard-tasks {
    grid-template-columns:1fr;
  }
  .dashboard-home .task-list {
    max-height:none;
    overflow:visible;
  }
  .collection-ring,.status-bar-fill {
    print-color-adjust:exact;
    -webkit-print-color-adjust:exact;
  }
}

/* 全站浅色Apple式皮肤：较高白色遮罩保留文字对比，不增加装饰性动画。 */
.app-glass {
  --glass:rgba(255,255,255,.84);
  --glass-border:rgba(255,255,255,.94);
  --glass-shadow:0 2px 8px rgba(37,65,78,.025),0 12px 32px rgba(37,65,78,.05);
  --control-border:#81969f;
  font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","Helvetica Neue","PingFang SC","Microsoft YaHei",system-ui,sans-serif;
}
.app-glass .panel {
  background:var(--glass);
  border:1px solid var(--glass-border);
  border-radius:18px;
  box-shadow:var(--glass-shadow);
  backdrop-filter:blur(16px);
  -webkit-backdrop-filter:blur(16px);
}
.app-glass .form-label {
  display:block;
  color:var(--ink);
  font-weight:600;
}
.app-glass .form-control,.app-glass .form-select {
  min-height:44px;
  max-width:100%;
  font-family:inherit;
  font-size:16px;
  font-size:max(16px,1rem);
  color:var(--ink);
  background-color:rgba(255,255,255,.94);
  border-color:var(--control-border);
  border-radius:11px;
  box-shadow:inset 0 1px 2px rgba(37,65,78,.025);
}
.app-glass .form-control::placeholder {
  color:#60747f;
  opacity:1;
}
.app-glass .form-control:focus,.app-glass .form-select:focus {
  border-color:var(--primary);
  background-color:#fff;
  box-shadow:0 0 0 3px rgba(19,124,144,.15);
}
/* 错误/只读反馈单独保留，不能被通用输入边框覆盖。 */
.app-glass .form-control:is(.is-invalid,[aria-invalid=true]),.app-glass .form-select:is(.is-invalid,[aria-invalid=true]) {
  border-color:var(--danger);
}
.app-glass .form-control:disabled,.app-glass .form-select:disabled,.app-glass .form-control[readonly] {
  background-color:rgba(235,241,244,.88);
  color:#506570;
}
.app-glass .form-check-input:checked {
  background-color:var(--primary);
  border-color:var(--primary);
}
.app-glass .btn {
  min-height:44px;
  border-radius:11px;
  font-family:inherit;
  font-weight:600;
}
.app-glass .btn-primary {
  --bs-btn-color:#fff;
  --bs-btn-bg:var(--primary);
  --bs-btn-border-color:var(--primary);
  --bs-btn-hover-color:#fff;
  --bs-btn-hover-bg:#106577;
  --bs-btn-hover-border-color:#106577;
  --bs-btn-active-color:#fff;
  --bs-btn-active-bg:#0e5a6b;
  --bs-btn-active-border-color:#0e5a6b;
  --bs-btn-focus-shadow-rgb:19,124,144;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.16),0 1px 3px rgba(26,87,101,.12);
}
.app-glass .btn-outline-primary {
  --bs-btn-color:#126d80;
  --bs-btn-bg:rgba(246,252,253,.82);
  --bs-btn-border-color:#829fa9;
  --bs-btn-hover-color:#0f6577;
  --bs-btn-hover-bg:#e4f1f4;
  --bs-btn-hover-border-color:#548b9a;
  --bs-btn-active-color:#0f6577;
  --bs-btn-active-bg:#d9ecf0;
  --bs-btn-active-border-color:#548b9a;
  --bs-btn-focus-shadow-rgb:19,124,144;
}
.app-glass .btn-outline-secondary {
  --bs-btn-color:#465c68;
  --bs-btn-bg:rgba(255,255,255,.7);
  --bs-btn-border-color:#9babb3;
  --bs-btn-hover-color:#304a58;
  --bs-btn-hover-bg:#edf2f4;
  --bs-btn-hover-border-color:#758f9b;
  --bs-btn-active-color:#304a58;
  --bs-btn-active-bg:#e3ecef;
  --bs-btn-active-border-color:#758f9b;
}
.app-glass .table-responsive {
  border-radius:12px;
}
.app-glass .table {
  --bs-table-bg:transparent;
  --bs-table-color:var(--ink);
  --bs-table-border-color:rgba(139,160,172,.2);
  --bs-table-hover-bg:rgba(226,239,242,.55);
}
.app-glass .table th {
  color:#506570;
  background:rgba(236,242,244,.85);
}
.app-glass .financial-grid,.app-glass .plain-note,.app-glass .evidence-data {
  background:rgba(241,246,248,.8);
  border-radius:12px;
}
.app-glass .evidence-card {
  border-color:rgba(139,160,172,.3);
  border-radius:12px;
  background:rgba(255,255,255,.45);
}

/* 原生dialog只有[open]才变为弹性布局，避免关闭后被作者样式误显示。 */
.app-glass:has(.registration-dialog[open]) {
  overflow:hidden;
}
.app-glass .registration-dialog {
  width:min(720px,calc(100vw - 32px));
  max-width:none;
  max-height:90vh;
  max-height:min(90dvh,calc(100dvh - 24px));
  padding:0;
  margin:auto;
  overflow:hidden;
  color:var(--ink);
  font:inherit;
  border:1px solid rgba(255,255,255,.96);
  border-radius:22px;
  background:rgba(255,255,255,.9);
  box-shadow:0 16px 56px rgba(30,53,66,.18),0 2px 8px rgba(30,53,66,.06);
  backdrop-filter:blur(24px);
  -webkit-backdrop-filter:blur(24px);
}
.app-glass .registration-dialog[open] {
  display:flex;
  flex-direction:column;
}
.app-glass .registration-dialog[open]::backdrop {
  background:rgba(26,43,53,.28);
  backdrop-filter:blur(6px);
  -webkit-backdrop-filter:blur(6px);
}
.registration-dialog-heading {
  display:flex;
  flex:none;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:22px 24px;
  border-bottom:1px solid rgba(139,160,172,.22);
  background:rgba(255,255,255,.64);
}
.registration-dialog-heading>div {
  min-width:0;
}
.registration-dialog-heading h2 {
  margin:0;
  font-size:1.2rem;
  font-weight:650;
  letter-spacing:-.015em;
  overflow-wrap:anywhere;
}
.registration-dialog-heading .eyebrow {
  margin-bottom:4px;
}
.dialog-close {
  display:inline-flex;
  flex:0 0 44px;
  width:44px;
  height:44px;
  align-items:center;
  justify-content:center;
  padding:0;
  color:#455e6b;
  background:rgba(236,242,244,.85);
  border:1px solid rgba(139,160,172,.22);
  border-radius:12px;
  font:inherit;
  font-size:1.5rem;
  line-height:1;
  cursor:pointer;
}
.dialog-close:hover {
  color:#263e4c;
  background:#e4edf1;
}
.registration-dialog-body {
  min-height:0;
  padding:24px;
  overflow-y:auto;
  overscroll-behavior:contain;
  scroll-padding:18px 0 104px;
}
.app-glass .registration-dialog .form-panel {
  max-width:none;
  margin:0;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
  box-shadow:none;
  backdrop-filter:none;
  -webkit-backdrop-filter:none;
}
.registration-dialog .form-control,.registration-dialog .form-select,.registration-dialog .error-summary {
  scroll-margin-top:18px;
  scroll-margin-bottom:104px;
}
/* 滚动表单的提交区保持实读遮罩；底部留白避免遮住键盘焦点或错误提示。 */
.registration-dialog .form-actions {
  position:sticky;
  bottom:-24px;
  z-index:1;
  margin:24px -24px -24px;
  padding:16px 24px;
  border-top:1px solid rgba(139,160,172,.22);
  background:rgba(255,255,255,.96);
  backdrop-filter:blur(12px);
  -webkit-backdrop-filter:blur(12px);
}
.registration-dialog-status {
  flex:none;
  margin:0;
  padding:12px 24px;
  border-top:1px solid rgba(139,160,172,.22);
  color:var(--muted);
  font-size:.875rem;
  overflow-wrap:anywhere;
}
.registration-dialog-status:empty {
  display:none;
}
@media(max-width:767px) {
  .app-glass .panel {
    border-radius:16px;
  }
  .app-glass .registration-dialog {
    width:calc(100vw - 24px);
    max-height:calc(100vh - 24px);
    max-height:calc(100dvh - 24px);
    border-radius:20px;
  }
  .registration-dialog-heading {
    padding:18px 16px;
    gap:12px;
  }
  .registration-dialog-body {
    padding:20px 16px 16px;
  }
  .registration-dialog .form-actions {
    bottom:-16px;
    margin:24px -16px -16px;
    padding:14px 16px;
  }
  .registration-dialog-status {
    padding:12px 16px;
  }
}
/* 无blur支持时用白色面板保留轮廓；不根据系统透明偏好取消用户选定的磨砂。 */
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
  .app-glass .panel,.app-glass .registration-dialog,.registration-dialog-heading,.registration-dialog .form-actions {
    background:#fbfcfd;
  }
}
@media print {
  .app-glass .panel,.app-glass .form-control,.app-glass .form-select {
    background:white;
    border-color:#bbb;
    box-shadow:none;
    backdrop-filter:none;
    -webkit-backdrop-filter:none;
  }
  .app-glass .registration-dialog {
    display:none!important;
  }
}

/* 服务器与更新页：沿用浅色磨砂面板；资源图保留数字，缺失数据不伪装为零。 */
.server-updates {
  display:grid;
  gap:18px;
  min-width:0;
}
.server-updates [hidden] {
  display:none!important;
}
.server-page-intro,.server-section-heading {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}
.server-page-intro p {
  margin:0;
  color:var(--muted);
  font-size:.9rem;
}
.server-version-pill,.server-neutral-badge {
  padding:6px 11px;
  border:1px solid rgba(139,160,172,.26);
  border-radius:100px;
  background:rgba(255,255,255,.64);
  color:var(--ink);
  font-size:.8125rem;
  font-weight:600;
  overflow-wrap:anywhere;
}
.server-version-pill {
  max-width:42%;
  flex-shrink:0;
}
.server-jump-nav {
  display:flex;
  align-items:center;
  gap:6px;
  padding:5px;
  width:fit-content;
  max-width:100%;
  border:1px solid rgba(139,160,172,.22);
  border-radius:14px;
  background:rgba(255,255,255,.54);
}
.server-jump-nav a {
  display:inline-flex;
  min-height:44px;
  align-items:center;
  padding:8px 15px;
  border-radius:10px;
  color:var(--ink);
  font-size:.875rem;
  text-decoration:none;
}
.server-jump-nav a:hover {
  background:rgba(231,240,245,.88);
}
.server-top-grid {
  display:grid;
  grid-template-columns:minmax(0,1.8fr) minmax(250px,1fr);
  gap:18px;
}
.server-updates #server-overview,.server-updates #update-upload,.server-updates #update-records {
  scroll-margin-top:100px;
}
.server-updates .panel {
  min-width:0;
  margin:0;
}
.server-section-heading {
  margin-bottom:18px;
}
.server-section-heading h2,.server-version-panel h2 {
  margin:0;
}
.server-section-heading .eyebrow,.server-version-panel>.eyebrow {
  margin-bottom:4px;
}
.server-metrics {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}
.server-metric-card {
  padding:15px 13px 12px;
  border:1px solid rgba(139,160,172,.22);
  border-radius:14px;
  background:rgba(255,255,255,.55);
}
.server-metric-card h3 {
  margin:0 0 9px;
  color:var(--muted);
  font-size:.8125rem;
  font-weight:600;
}
.server-metric-card strong {
  display:block;
  margin-bottom:13px;
  font-size:1.6rem;
  font-weight:650;
  line-height:1.15;
  letter-spacing:-.03em;
  font-variant-numeric:tabular-nums;
}
.server-metric-card progress {
  display:block;
  appearance:none;
  -webkit-appearance:none;
  width:100%;
  height:7px;
  border:0;
  border-radius:20px;
  background:rgba(149,169,182,.2);
  overflow:hidden;
  accent-color:var(--primary);
}
.server-metric-card progress::-webkit-progress-bar {
  background:rgba(149,169,182,.2);
  border-radius:20px;
}
.server-metric-card progress::-webkit-progress-value {
  background:var(--primary);
  border-radius:20px;
}
.server-metric-card progress::-moz-progress-bar {
  background:var(--primary);
  border-radius:20px;
}
.server-metric-card p {
  margin:10px 0 0;
  color:var(--muted);
  font-size:.8125rem;
  overflow-wrap:anywhere;
}
.server-host-facts {
  display:flex;
  flex-wrap:wrap;
  gap:8px 24px;
  margin:18px 0 14px;
  font-size:.8125rem;
}
.server-host-facts>div {
  display:flex;
  gap:8px;
  min-width:0;
}
.server-host-facts dt,.server-version-list dt,.server-update-detail dt {
  color:var(--muted);
  font-weight:500;
}
.server-host-facts dd,.server-version-list dd,.server-update-detail dd {
  margin:0;
  overflow-wrap:anywhere;
}
.server-sample-meta p {
  margin:4px 0;
  color:var(--muted);
  font-size:.8125rem;
}
.server-resource-notes {
  padding-left:18px;
  margin:10px 0 0;
  color:var(--muted);
  font-size:.8125rem;
}
.server-version-list {
  margin:20px 0 0;
  font-size:.875rem;
}
.server-version-list>div {
  display:grid;
  grid-template-columns:64px minmax(0,1fr);
  gap:12px;
  padding:9px 0;
  border-bottom:1px solid rgba(139,160,172,.18);
}
.server-version-list dd {
  font-weight:600;
}
.server-release-note {
  margin-top:16px;
  color:var(--muted);
  font-size:.8125rem;
}
.server-release-note h3 {
  margin:0 0 7px;
  font-size:.875rem;
  color:var(--ink);
}
.server-release-note p {
  margin:0 0 7px;
}
.server-release-note ul {
  padding-left:18px;
  margin:0;
}
.server-upload-grid {
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  gap:26px;
}
.server-upload-explanation {
  padding:17px 20px;
  border:1px solid rgba(139,160,172,.18);
  border-radius:14px;
  background:rgba(235,243,247,.62);
  color:var(--muted);
  font-size:.875rem;
}
.server-upload-explanation h3 {
  margin:0 0 12px;
  color:var(--ink);
  font-size:.95rem;
}
.server-upload-explanation ol {
  padding-left:20px;
  margin:0 0 14px;
}
.server-upload-explanation li+li {
  margin-top:7px;
}
.server-upload-explanation p {
  margin:8px 0 0;
}
.server-records-intro {
  margin:0 0 18px;
  color:var(--muted);
  font-size:.875rem;
}
.server-updates-table {
  min-width:820px;
  table-layout:fixed;
}
.server-updates-table th:nth-child(1) {width:22%}
.server-updates-table th:nth-child(2) {width:20%}
.server-updates-table th:nth-child(3) {width:20%}
.server-updates-table th:nth-child(4) {width:38%}
.server-updates-table td {
  vertical-align:top;
  overflow-wrap:anywhere;
}
.server-package-name,.server-version-change {
  display:block;
  font-size:.875rem;
}
.server-updates-table .cell-secondary {
  display:block;
  margin-top:5px;
  font-size:.8125rem;
}
.server-package-download {
  display:inline-flex;
  align-items:center;
  min-height:44px;
  font-size:.8125rem;
}
.server-update-state {
  display:inline-block;
  padding:4px 8px;
  margin-top:7px;
  border-radius:8px;
  background:rgba(224,234,241,.8);
  color:#355364;
  font-size:.8125rem;
  font-weight:600;
}
.server-update-state-published {
  background:#e5f1eb;
  color:#256348;
}
.server-update-state-publish_failed,.server-update-state-rejected {
  background:#f6e9e9;
  color:#8c333d;
}
.server-update-detail summary {
  display:list-item;
  min-height:44px;
  padding:6px 0;
  color:var(--primary);
  font-size:.875rem;
  cursor:pointer;
}
.server-update-detail dl {
  margin:8px 0 12px;
  font-size:.8125rem;
}
.server-update-detail dl>div+div {
  margin-top:12px;
}
.server-update-detail code {
  color:var(--ink);
  font-size:.75rem;
  overflow-wrap:anywhere;
}
.server-update-detail .server-release-text {
  white-space:pre-line;
}
.server-update-detail form {
  padding-top:10px;
  border-top:1px solid rgba(139,160,172,.22);
}
.server-update-detail .form-label {
  display:block;
  margin-top:14px;
  font-size:.8125rem;
}
.server-update-detail form>.btn {
  margin-top:15px;
}
/* 原生文件选择与提交按钮使用胶囊轮廓；阴影呈现浮空感，不改变表单位置。 */
.app-glass input[type="file"].file-pill {
  min-height:56px;
  padding:6px;
  border:0;
  border-radius:28px;
  background:transparent;
  box-shadow:none;
  overflow:visible;
}
.file-pill::file-selector-button {
  min-height:44px;
  margin:0 12px 0 0;
  padding:8px 20px;
  border:1px solid rgba(18,104,117,.24);
  border-radius:999px;
  background:rgba(255,255,255,.94);
  color:var(--ink);
  font:inherit;
  font-weight:600;
  box-shadow:0 5px 12px rgba(17,65,77,.16),0 1px 2px rgba(17,65,77,.09);
  cursor:pointer;
}
.app-glass .server-upload-panel form>.btn-primary {
  min-height:44px;
  padding:10px 26px;
  border-radius:999px;
  box-shadow:0 7px 16px rgba(14,106,119,.22),0 2px 4px rgba(14,106,119,.12);
  transition:transform .18s ease,box-shadow .18s ease;
}
@media(hover:hover) and (prefers-reduced-motion:no-preference) {
  .app-glass .server-upload-panel form>.btn-primary:hover:not(:disabled) {
    transform:translateY(-2px);
    box-shadow:0 10px 22px rgba(14,106,119,.27),0 3px 5px rgba(14,106,119,.12);
  }
}
.app-glass .server-upload-panel form>.btn-primary:active:not(:disabled) {
  transform:translateY(0);
  box-shadow:0 3px 8px rgba(14,106,119,.18);
}
.app-glass .server-upload-panel form>.btn-primary:disabled {
  transform:none;
  box-shadow:none;
}
@media(prefers-reduced-motion:reduce) {
  .app-glass .server-upload-panel form>.btn-primary { transition:none; }
}
@media(max-width:1100px) {
  .server-top-grid {
    grid-template-columns:minmax(0,1fr);
  }
  .server-version-list {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:0 24px;
  }
}
@media(max-width:620px) {
  .server-page-intro {
    align-items:flex-start;
    flex-direction:column;
    gap:10px;
  }
  .server-version-pill {
    max-width:100%;
  }
  .server-jump-nav {
    width:100%;
    gap:0;
  }
  .server-jump-nav a {
    flex:1;
    justify-content:center;
    padding:8px 5px;
    font-size:.8125rem;
  }
  .server-section-heading {
    gap:10px;
  }
  .server-section-heading>.btn {
    padding:8px 12px;
    font-size:.8125rem;
  }
  .server-metrics {
    grid-template-columns:minmax(0,1fr);
  }
  .server-metric-card {
    display:grid;
    grid-template-columns:1fr 1fr;
    align-items:center;
    gap:8px;
    padding:13px;
  }
  .server-metric-card h3,.server-metric-card strong {
    margin:0;
  }
  .server-metric-card strong {
    font-size:1.45rem;
    text-align:right;
  }
  .server-metric-card progress,.server-metric-card p {
    grid-column:1/-1;
  }
  .server-metric-card p {
    margin:0;
  }
  .server-version-list,.server-upload-grid {
    grid-template-columns:minmax(0,1fr);
  }
  .server-upload-grid {
    gap:20px;
  }
  .server-neutral-badge {
    max-width:45%;
    text-align:center;
  }
}

/* 主题和轻动效沿用现有布局；深色覆盖包括表单、图表和业务状态。 */
.app-glass {
  --line:var(--border);
  --accent:#126d80;
}
.workspace-tools { display:flex; align-items:center; gap:10px; margin-left:auto; }
.workspace-tools .theme-select { width:134px; font-size:.875rem; }
.nav-step { display:inline-grid; place-items:center; width:22px; height:22px; flex:none; margin-right:10px; border:1px solid currentColor; border-radius:7px; font-size:.75rem; }
.nav-group { border-top:1px solid var(--line); margin-top:12px; padding-top:8px; }
.nav-group>summary,.account-disclosure>summary { display:flex; align-items:center; min-height:44px; gap:8px; cursor:pointer; list-style:none; border-radius:10px; }
.nav-group>summary::-webkit-details-marker,.account-disclosure>summary::-webkit-details-marker { display:none; }
.nav-group>summary::after,.account-disclosure>summary::after { content:''; width:7px; height:7px; margin-left:auto; border-right:2px solid currentColor; border-bottom:2px solid currentColor; transform:rotate(45deg); }
.nav-group[open]>summary::after,.account-disclosure[open]>summary::after { transform:rotate(225deg); }
.nav-group>summary { padding:10px 14px; color:var(--muted); font-size:.85rem; font-weight:600; }
.nav-group>summary:hover,.account-disclosure>summary:hover { background:var(--palette-soft,var(--canvas)); color:var(--accent); }
.app-glass .sidebar .nav-group>a { padding-left:24px; font-size:.875rem; }
.app-glass .account-disclosure { position:relative; display:block; flex:none; }
.account-disclosure>summary { padding:8px 12px; border:1px solid var(--line); font-weight:600; }
.account-disclosure .account-name { display:inline-block; max-width:160px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
.account-panel { position:absolute; right:0; top:calc(100% + 10px); width:min(290px,calc(100vw - 32px)); max-height:calc(100dvh - 90px); overflow-y:auto; padding:20px; color:var(--ink); background:var(--surface); border:1px solid var(--line); border-radius:14px; box-shadow:0 12px 32px #17324d26; }
.account-panel-name { margin:0 0 16px; font-weight:650; overflow-wrap:anywhere; }
.account-panel .form-label { display:block; margin:14px 0 6px; }
.account-panel-actions { display:grid; gap:8px; margin-top:20px; padding-top:16px; border-top:1px solid var(--line); }
.account-panel-actions .btn { width:100%; }
.command-trigger { gap:12px; white-space:nowrap; }
.command-trigger kbd { padding:2px 5px; font-size:.72rem; color:var(--muted); background:var(--canvas); border:1px solid var(--line); border-radius:5px; }
.app-glass:has(.command-dialog[open]) { overflow:hidden; }
.app-glass .btn,.dialog-close,.sidebar nav a { transition:background-color .15s,color .15s,transform .15s,box-shadow .15s; }
.app-glass .btn:active:not(:disabled),.dialog-close:active { transform:scale(.98); }
.app-glass .registration-dialog[open] { animation:dialog-enter .18s cubic-bezier(.2,.8,.2,1); }
.app-glass .messages { animation:content-enter .2s ease-out; }
.app-glass .dashboard-kpis { animation:content-enter .22s ease-out; }
@keyframes dialog-enter { from { opacity:0; transform:translateY(6px) scale(.985); } to { opacity:1; transform:none; } }
@keyframes content-enter { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:none; } }
@media(hover:hover) and (prefers-reduced-motion:no-preference) {
  .app-glass .btn:hover:not(:disabled) { transform:translateY(-1px); }
}
@media(max-width:1050px) { .workspace-tools .command-trigger kbd { display:none; } }
@media(max-width:767px) {
  .workspace-tools { width:100%; margin:0; gap:12px; }
  .workspace-tools .command-trigger,.workspace-tools .theme-select { flex:1; width:auto; min-width:0; }
  .app-glass .account-menu { gap:12px; flex-wrap:wrap; }
  .app-glass .topbar { display:grid; grid-template-columns:auto minmax(0,1fr) auto; }
  .app-glass .topbar .brand { grid-column:2/-1; }
  .workspace-tools { grid-column:1/3; }
  .account-disclosure .account-name { display:none; }
  .nav-group { grid-column:1/-1; margin-top:4px; }
  .app-glass .sidebar.is-open { animation:content-enter .16s ease-out; }
}
html[data-bs-theme=dark],html[data-bs-theme=dark] .app-glass {
  --ink:#e3edf3; --muted:#a6bbc7; --border:#3c5261; --line:#3c5261;
  --surface:#1b2b36; --canvas:#101c25; --primary:#187e90; --accent:#79d5e2;
  --danger:#ffafb5; --warning:#f3cc86; --chart-track:#314652;
  --glass:rgba(27,43,54,.9); --glass-border:rgba(108,139,156,.28);
  --glass-shadow:0 2px 8px #0002,0 12px 32px #0002; --control-border:#6c8797;
}
html[data-bs-theme=dark] body { background:var(--canvas); }
html[data-bs-theme=dark] .app-glass { background:radial-gradient(ellipse at 2% 15%,#19485445,transparent 42%),#101c25; }
html[data-bs-theme=dark] a { color:var(--accent); }
html[data-bs-theme=dark] a:hover { color:#b5edf3; }
html[data-bs-theme=dark] .app-glass :is(.topbar,.sidebar,.registration-dialog,.command-dialog) { background:var(--glass); border-color:var(--glass-border); }
html[data-bs-theme=dark] :is(.registration-dialog-heading,.registration-dialog .form-actions) { background:#1b2b36f5; }
html[data-bs-theme=dark] .app-glass :is(.sidebar nav a,.brand,.account-menu a) { color:var(--ink); }
html[data-bs-theme=dark] .app-glass .brand-mark { background:#233f4b; color:var(--accent); border-color:var(--line); }
html[data-bs-theme=dark] .app-glass .sidebar nav a:is(:hover,[aria-current=page]) { background:#25434f; color:var(--accent); }
html[data-bs-theme=dark] :is(.dialog-close,.ring-center,.financial-grid,.plain-note,.evidence-data,.server-upload-explanation) { color:var(--ink); background:#243845; }
html[data-bs-theme=dark] .dialog-close:hover { color:var(--ink); background:#314b5b; }
html[data-bs-theme=dark] .app-glass :is(.form-control,.form-select) { color:var(--ink); background-color:#15252f; border-color:var(--control-border); }
html[data-bs-theme=dark] .app-glass :is(.form-control,.form-select):focus { background-color:#1b303c; border-color:var(--accent); }
html[data-bs-theme=dark] .app-glass .form-control::placeholder { color:#a6bbc7; }
html[data-bs-theme=dark] .app-glass :is(.form-control:disabled,.form-control[readonly],.form-select:disabled) { color:#b5c6d0; background-color:#2a3e4b; }
html[data-bs-theme=dark] .app-glass :is(.form-control,.form-select):is(.is-invalid,[aria-invalid=true]) { border-color:var(--danger); }
html[data-bs-theme=dark] :is(a,button,input,select,textarea,summary):focus-visible { outline-color:var(--accent)!important; }
html[data-bs-theme=dark] .app-glass .btn-primary { --bs-btn-bg:#16788a; --bs-btn-border-color:#16788a; --bs-btn-hover-bg:#116576; --bs-btn-hover-border-color:#116576; }
html[data-bs-theme=dark] .app-glass :is(.btn-outline-primary,.btn-outline-secondary,.btn-outline-light) {
  --bs-btn-color:var(--ink); --bs-btn-bg:#1d3340; --bs-btn-border-color:#718b99;
  --bs-btn-hover-color:#fff; --bs-btn-hover-bg:#2c4b5c; --bs-btn-hover-border-color:#99bac9;
  --bs-btn-active-color:#fff; --bs-btn-active-bg:#2c4b5c; --bs-btn-active-border-color:#99bac9;
}
html[data-bs-theme=dark] .app-glass .btn-outline-danger { --bs-btn-color:#ffb5bb; --bs-btn-border-color:#cc767f; }
html[data-bs-theme=dark] .app-glass .table { --bs-table-color:var(--ink); --bs-table-border-color:var(--line); }
html[data-bs-theme=dark] .app-glass .table th { color:var(--muted); background:#253b48; }
html[data-bs-theme=dark] :is(.evidence-card,.server-metric-card,.server-version-pill,.server-neutral-badge,.server-jump-nav) { background:#203440; border-color:var(--line); }
html[data-bs-theme=dark] .evidence-card blockquote { color:var(--muted); }
html[data-bs-theme=dark] .dashboard-home .kpi-attention { background:#203f49; border-color:#3c626f; }
html[data-bs-theme=dark] .kpi-attention .kpi-value { color:var(--accent); }
html[data-bs-theme=dark] :is(.status-bar-track,.legend-dot-unpaid) { background:var(--chart-track); }
html[data-bs-theme=dark] :is(.status-bar-row:hover,.server-jump-nav a:hover) { color:var(--ink); background:#263e4c; }
html[data-bs-theme=dark] :is(.status,.settlement,.server-update-state) { color:#c3d6e1; background:#2b4353; }
html[data-bs-theme=dark] .status-drafting { color:#b8dcff; background:#274660; }
html[data-bs-theme=dark] :is(.status-opening,.settlement-unpaid,.settlement-partial,.reminder-label) { color:#ffe0a5; background:#53452e; }
html[data-bs-theme=dark] :is(.status-won,.settlement-paid,.server-update-state-published) { color:#b4edd0; background:#264c3d; }
html[data-bs-theme=dark] :is(.status-invalid,.status-withdrawn,.server-update-state-publish_failed,.server-update-state-rejected) { color:#ffbac1; background:#542f38; }
html[data-bs-theme=dark] .login-card { color:var(--ink); background:var(--surface); border-color:var(--line); }
html[data-bs-theme=dark] .login-logo { background:#245363; color:#fff; }
html[data-bs-theme=dark] .file-pill::file-selector-button { color:var(--ink); background:#294452; border-color:var(--line); }
html[data-bs-theme=dark] .skip-link { color:var(--ink); background:var(--surface); }
@supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))) {
  html[data-bs-theme=dark] .app-glass :is(.topbar,.sidebar,.panel,.registration-dialog,.command-dialog) { background:#1b2b36; }
}
@media(prefers-reduced-motion:reduce) {
  .app-glass .btn:is(:hover,:active),.dialog-close:active { transform:none!important; }
}
@media print {
  html[data-bs-theme=dark],html[data-bs-theme=dark] .app-glass {
    --ink:#17324d; --muted:#58697b; --surface:white; --canvas:white;
    --border:#bbb; --line:#bbb; --accent:#205d91; --glass:white; --glass-border:#bbb;
    color-scheme:light!important;
  }
  html[data-bs-theme=dark] .app-glass { background:white; }
  html[data-bs-theme=dark] .app-glass :is(.panel,.kpi-card,.form-control,.form-select,.table th,.ring-center,.financial-grid,.plain-note,.evidence-data) { background:white; color:var(--ink); }
  .workspace-tools,.command-dialog { display:none!important; }
}
