:root {
  --ink: #1b2638;
  --muted: #667085;
  --line: #d8dee8;
  --blue: #1f5f99;
  --blue-dark: #113b60;
  --gold: #b98222;
  --paper: #f5f7fb;
  --white: #ffffff;
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
}
body.dialog-open {
  overflow: hidden;
}
a { color: inherit; text-decoration: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 5vw;
  background: rgba(255,255,255,.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.brand-logo {
  display: block;
  width: 46px;
  height: 46px;
  object-fit: contain;
  flex: 0 0 auto;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  color: white;
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  font-weight: 800;
}
.brand strong { display: block; font-size: 17px; }
.brand small { display: block; color: var(--muted); font-size: 11px; }
.brand.compact strong { font-size: 15px; }
.brand.compact .brand-logo {
  width: 42px;
  height: 42px;
}
.login-info .brand small,
.sidebar .brand small {
  color: rgba(255,255,255,.72);
}

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  color: #344054;
  font-size: 14px;
}
.nav-action {
  padding: 9px 14px;
  color: white;
  background: var(--blue);
  border-radius: 6px;
}

.hero {
  position: relative;
  min-height: 620px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(13,31,50,.88), rgba(13,31,50,.54), rgba(13,31,50,.2)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1600' height='900' viewBox='0 0 1600 900'%3E%3Crect width='1600' height='900' fill='%238995a3'/%3E%3Cpath d='M0 630 C270 520 470 570 720 500 C1010 420 1220 470 1600 350 L1600 900 L0 900Z' fill='%2356636d'/%3E%3Cpath d='M0 710 C340 620 560 670 850 590 C1120 515 1320 560 1600 470 L1600 900 L0 900Z' fill='%233b4652'/%3E%3Cpath d='M180 660 L1360 420' stroke='%23d9dde3' stroke-width='44' opacity='.86'/%3E%3Cpath d='M250 720 L1440 480' stroke='%23aeb7c2' stroke-width='16' opacity='.95'/%3E%3Cpath d='M900 285 h260 v96 h-260z' fill='%23d4a33a'/%3E%3Cpath d='M1010 145 h36 v140 h-36z' fill='%23f2c04d'/%3E%3Cpath d='M1046 164 l250 52' stroke='%23f2c04d' stroke-width='16'/%3E%3Ccircle cx='936' cy='394' r='30' fill='%23263037'/%3E%3Ccircle cx='1122' cy='394' r='30' fill='%23263037'/%3E%3Cpath d='M200 330 h210 v130 h-210z' fill='%23c9d1d9'/%3E%3Cpath d='M220 280 h170 v50 h-170z' fill='%23eef2f5'/%3E%3Cpath d='M570 300 h70 v260 h-70zM670 245 h70 v315 h-70zM770 335 h70 v225 h-70z' fill='%23b8c0ca' opacity='.85'/%3E%3C/svg%3E") center/cover no-repeat;
}
.hero-content {
  position: relative;
  width: min(760px, 90vw);
  margin-left: 5vw;
  color: white;
}
.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}
.hero h1 {
  margin: 0;
  font-size: clamp(48px, 8vw, 86px);
  letter-spacing: 0;
}
.lead {
  max-width: 680px;
  color: rgba(255,255,255,.86);
  font-size: 20px;
  line-height: 1.7;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
}
.button.primary { color: white; background: var(--blue); }
.button.secondary { color: var(--blue-dark); background: white; border-color: var(--line); }
.button.app-download {
  color: #0f7a42;
  border-color: rgba(15, 122, 66, .36);
  background: #f4fbf7;
}
.button.tool-service {
  color: #7b4f0c;
  border-color: rgba(185, 130, 34, .38);
  background: #fff8e9;
}
.button.disabled {
  color: #667085;
  border-color: #d8dee8;
  background: #eef2f6;
  cursor: not-allowed;
}
.button.full { width: 100%; }

.section {
  width: min(1180px, 90vw);
  margin: 72px auto;
}
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}
.section h2, .band h2 { margin: 0; font-size: 30px; letter-spacing: 0; }
.service-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.card, .module, .kpi-grid article, .process-grid article {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.card { padding: 22px; min-height: 170px; }
.card h3, .module h2 { margin: 0 0 10px; }
.card p, .module p { color: var(--muted); line-height: 1.7; }

.tools-main {
  min-height: 70vh;
}
.tools-hero {
  padding: 76px 5vw 56px;
  color: white;
  background:
    linear-gradient(135deg, rgba(17,59,96,.96), rgba(31,95,153,.82)),
    radial-gradient(circle at 82% 24%, rgba(185,130,34,.34), transparent 34%);
}
.tools-hero h1 {
  margin: 0;
  font-size: clamp(42px, 6vw, 72px);
  letter-spacing: 0;
}
.tools-hero p:last-child {
  max-width: 850px;
  margin: 18px 0 0;
  color: rgba(255,255,255,.84);
  font-size: 19px;
  line-height: 1.8;
}
.tools-section {
  width: min(1180px, 90vw);
  margin: 46px auto;
}
.section-head.compact {
  align-items: center;
}
.tools-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.tool-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 360px;
  padding: 26px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.tool-card-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}
.tool-card h3 {
  margin: 0;
  font-size: 28px;
}
.tool-card p {
  margin: 0;
  color: #475467;
  line-height: 1.8;
}
.tool-status {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  color: #0f5132;
  background: #e8f5ee;
  font-size: 13px;
  font-weight: 700;
}
.tool-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}
.tool-meta div,
.tool-release-note {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.tool-meta dt {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
}
.tool-meta dd {
  margin: 0;
  font-weight: 700;
}
.tool-release-note strong {
  display: block;
  margin-bottom: 6px;
}
.tool-boundary {
  margin: 0;
  padding: 12px 14px;
  border-left: 3px solid #2f6ea5;
  background: #f2f7fc;
  color: var(--muted);
  border-radius: 6px;
}
.tool-actions {
  margin-top: auto;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.tool-note-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.tool-note-grid article {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.tool-note-grid h3 {
  margin: 0 0 10px;
}
.tool-note-grid p {
  margin: 0;
  color: #475467;
  line-height: 1.8;
}

.about-layout {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 26px;
  align-items: start;
}
.about-copy {
  padding: 28px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.about-copy p {
  margin: 0 0 12px;
  color: #475467;
  font-size: 17px;
  line-height: 1.9;
}
.about-copy p:last-child { margin-bottom: 0; }
.about-checks {
  display: grid;
  gap: 10px;
}
.about-checks span {
  display: block;
  padding: 15px 16px;
  border-left: 4px solid var(--gold);
  border-radius: 6px;
  background: #fff;
  color: #1f3a5f;
  font-weight: 700;
}

.band {
  display: grid;
  grid-template-columns: 1.2fr .8fr;
  gap: 28px;
  align-items: center;
  padding: 48px 5vw;
  background: #0f2f4d;
  color: white;
}
.band p { color: rgba(255,255,255,.78); line-height: 1.8; }
.metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 0;
}
.metrics div {
  padding: 18px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 8px;
  background: rgba(255,255,255,.08);
}
.metrics dt {
  font-size: clamp(24px, 2vw, 30px);
  font-weight: 800;
  line-height: 1.2;
}
.metrics dd { margin: 4px 0 0; color: rgba(255,255,255,.76); }

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.process-grid article {
  padding: 22px;
}
.process-grid span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 32px;
  margin-bottom: 18px;
  border-radius: 999px;
  background: #e8eef5;
  color: var(--blue-dark);
  font-weight: 800;
}
.process-grid h3 {
  margin: 0 0 10px;
}
.process-grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.partner-band {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  width: min(1180px, 90vw);
  margin: 72px auto;
  padding: 34px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 14px 40px rgba(16, 42, 67, .08);
}
.partner-band h2 { margin: 0; font-size: 28px; }
.partner-band p:not(.eyebrow) {
  max-width: 760px;
  color: var(--muted);
  line-height: 1.8;
}
.partner-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  gap: 24px;
  padding: 24px 5vw;
  color: #d9e2ec;
  background: #101828;
}
.footer-copyright {
  grid-column: 1;
  justify-self: start;
  color: #aeb8c5;
  font-size: 15px;
  white-space: nowrap;
}
.footer-site {
  grid-column: 3;
  justify-self: end;
  text-align: right;
  font-size: 15px;
  white-space: nowrap;
}
.footer span { display: block; margin: 4px 0; color: #aeb8c5; }
.footer a {
  color: inherit;
  text-decoration: none;
}
.footer a:hover { color: #fff; }
.footer-beian {
  grid-column: 2;
  justify-self: center;
  display: inline-flex !important;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 16px;
  color: #d9e2ec;
}
.gongan-beian-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.gongan-beian-link img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.login-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #102a43, #243b53);
}
.login-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 48px;
  align-items: center;
  width: min(1120px, 90vw);
  margin: 0 auto;
}
.login-info { color: white; }
.login-info h1 { font-size: 48px; margin: 42px 0 14px; }
.login-info p { max-width: 600px; color: rgba(255,255,255,.78); line-height: 1.8; }
.login-points { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 24px; }
.login-points span {
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px;
  color: rgba(255,255,255,.86);
}
.login-modules {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 28px;
}
.login-modules article {
  padding: 16px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 8px;
  background: rgba(255,255,255,.08);
}
.login-modules strong {
  display: block;
  margin-bottom: 8px;
}
.login-modules span {
  color: rgba(255,255,255,.74);
  line-height: 1.6;
}
.login-card {
  padding: 30px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 22px 60px rgba(0,0,0,.28);
}
.login-card h2 { margin-top: 0; }
label { display: block; margin: 16px 0; font-weight: 700; }
input, select {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  border: 1px solid #cfd6e1;
  border-radius: 6px;
  font: inherit;
}
.form-note { color: var(--muted); font-size: 13px; line-height: 1.6; }
.inline-form .form-note,
.dialog-form .form-note {
  display: block;
  margin-top: 6px;
  font-weight: 500;
}
.inline-form label.is-disabled,
.dialog-form label.is-disabled {
  color: #7a8795;
}
.inline-form label.is-disabled input,
.inline-form label.is-disabled select,
.dialog-form label.is-disabled input,
.dialog-form label.is-disabled select {
  background: #eef2f6;
  color: #758294;
  cursor: not-allowed;
}
.security-note {
  margin-top: 18px;
  padding: 14px;
  border-radius: 6px;
  background: #f5f7fb;
  border: 1px solid var(--line);
}
.security-note strong { color: var(--blue-dark); }
.security-note p { margin: 6px 0 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
[data-status] {
  color: var(--muted);
}
[data-status][data-type="success"] {
  color: #147a46;
}
[data-status][data-type="error"] {
  color: #b42318;
}

.workspace-page { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.sidebar {
  padding: 18px;
  background: #102a43;
  color: white;
}
.sidebar nav { display: grid; gap: 8px; margin-top: 34px; }
.sidebar nav a {
  padding: 11px 12px;
  border-radius: 6px;
  color: rgba(255,255,255,.78);
}
.sidebar nav a.active, .sidebar nav a:hover { background: rgba(255,255,255,.12); color: white; }
.workspace-nav-group {
  display: grid;
  gap: 4px;
}
.workspace-nav-group-toggle {
  position: relative;
  width: 100%;
  min-height: 42px;
  padding: 10px 34px 10px 12px;
  border: 0;
  border-radius: 6px;
  color: rgba(255,255,255,.88);
  background: transparent;
  text-align: left;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.workspace-nav-group-toggle::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  font-size: 18px;
  font-weight: 400;
}
.workspace-nav-group.open > .workspace-nav-group-toggle,
.workspace-nav-group-toggle:hover {
  color: white;
  background: rgba(255,255,255,.08);
}
.workspace-nav-group.open > .workspace-nav-group-toggle::after { content: "−"; }
.workspace-nav-children {
  display: none;
  gap: 3px;
}
.workspace-nav-group.open > .workspace-nav-children { display: grid; }
.sidebar .workspace-nav-children a {
  min-height: 38px;
  padding: 9px 12px 9px 28px;
  font-size: 14px;
}
.target-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.target-summary-grid article {
  min-height: 92px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
}
.target-summary-grid span,
.target-summary-grid small { display: block; color: var(--muted); }
.target-summary-grid strong { display: block; margin: 7px 0 4px; font-size: 21px; color: var(--blue-dark); }
.workspace { padding: 28px; }
.workspace-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.workspace-top h1 { margin: 0; }
.workspace-user {
  margin: 8px 0 0;
  color: var(--muted);
}
.workspace-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}
.workspace-switcher {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  max-width: min(520px, 48vw);
}
.workspace-switch-button {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  color: var(--blue-dark);
  font-weight: 800;
  cursor: pointer;
}
.workspace-switch-button:hover {
  border-color: var(--blue);
  background: #eff6ff;
}
.workspace-switch-button.active {
  border-color: #0f4f84;
  background: #1f5f99;
  color: white;
}
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 24px 0;
}
.kpi-grid article { padding: 18px; }
.kpi-grid span, .kpi-grid small { color: var(--muted); }
.kpi-grid strong { display: block; margin: 8px 0; font-size: 34px; }
.module-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.module { padding: 22px; }
.workspace-panel {
  margin: 18px 0;
  background: white;
}
.panel-note {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.7;
}
.suggestion-box,
.ai-status {
  margin: 10px 0 16px;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: #17324d;
}
.suggestion-box strong,
.ai-status strong {
  display: block;
  margin-bottom: 6px;
}
.suggestion-box span,
.ai-status span,
.suggestion-box small {
  display: block;
  color: var(--muted);
}
.suggestion-box p {
  margin: 6px 0;
  color: #34495e;
}
.live-module {
  margin-top: 16px;
}
.module-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0;
  margin: 16px 0 0;
  list-style: none;
}
.module-list li {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
}
.module-list strong {
  display: block;
  margin-bottom: 4px;
}
.module-list span {
  display: block;
  color: var(--muted);
  line-height: 1.6;
}
.module button {
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  color: var(--blue);
  font-weight: 700;
}
.task-form {
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
}
.task-form label.wide {
  grid-column: span 2;
}
.task-detail {
  margin-top: 14px;
  padding: 16px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #f8fbff;
}
.task-detail h3 {
  margin: 0;
  color: var(--blue-dark);
}
.task-detail p {
  color: #475467;
  line-height: 1.7;
}
.task-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.task-detail-grid ul {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 8px 0 0;
  list-style: none;
}
.task-detail-grid li {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
}
.task-detail-grid li strong,
.task-detail-grid li span {
  display: block;
}
.task-detail-grid li span {
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.6;
}
.settlement-panel {
  display: grid;
  gap: 18px;
}
.settlement-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.settlement-actions button {
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  color: var(--blue);
  font-weight: 800;
  cursor: pointer;
}
.settlement-actions button:hover {
  border-color: var(--blue);
  background: #f1f7fc;
}
.settlement-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.settlement-kpis article {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.settlement-kpis span,
.settlement-kpis small {
  display: block;
  color: var(--muted);
}
.settlement-kpis strong {
  display: block;
  margin: 6px 0;
  color: var(--blue-dark);
  font-size: 22px;
  line-height: 1.2;
  word-break: break-all;
}
.settlement-block {
  display: grid;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.subsection-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.settlement-block h3 {
  margin: 0;
  color: #17324d;
  font-size: 18px;
}
.compact-kpis strong {
  font-size: 20px;
}
.settlement-form {
  grid-template-columns: repeat(5, minmax(0, 1fr)) auto;
}
.operation-form {
  grid-template-columns: repeat(6, minmax(0, 1fr)) auto;
}
.operation-filter-bar {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr)) minmax(130px, auto) minmax(220px, 1.5fr) auto minmax(130px, auto);
  gap: 8px;
  align-items: center;
  margin: 10px 0;
}
.operation-filter-bar select,
.operation-filter-bar input {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: #17324d;
}
.operation-filter-bar button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #b9c9da;
  border-radius: 6px;
  background: #ffffff;
  color: var(--blue);
  font-weight: 800;
  cursor: pointer;
}
.operation-filter-bar button:hover {
  border-color: var(--blue);
  background: #eef6ff;
}
.operation-filter-check {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
  color: #17324d;
  font-size: 13px;
  font-weight: 800;
}
.operation-filter-check input {
  width: auto;
  min-height: auto;
  margin: 0;
  padding: 0;
}
.operation-filter-bar [data-operation-filter-result] {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-align: right;
}
.operation-group-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 8px 0 12px;
}
.operation-group-summary section {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.operation-group-summary strong {
  display: block;
  margin-bottom: 8px;
  color: #17324d;
  font-size: 13px;
}
.operation-group-summary section > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.operation-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 5px 8px;
  border: 1px solid #c9d8e8;
  border-radius: 999px;
  background: #f8fbff;
  color: #17324d;
  font-size: 12px;
  font-weight: 700;
}
.operation-chip b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #1f5f99;
  color: #ffffff;
  font-size: 12px;
}
.operation-chip small {
  color: #567089;
  font-size: 12px;
}
.operation-chip.muted {
  color: var(--muted);
}
.operation-bulk-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px 12px;
  border: 1px solid #c9d8e8;
  border-radius: 8px;
  background: #f8fbff;
}
.operation-bulk-bar > div {
  display: grid;
  gap: 2px;
  min-width: 220px;
  margin-right: auto;
}
.operation-bulk-bar strong {
  color: #17324d;
  font-size: 14px;
}
.operation-bulk-bar span {
  color: var(--muted);
  font-size: 12px;
}
.operation-bulk-bar button {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #b9c9da;
  border-radius: 6px;
  background: #ffffff;
  color: var(--blue);
  font-weight: 800;
  cursor: pointer;
}
.operation-bulk-bar button:hover:not(:disabled) {
  border-color: var(--blue);
  background: #eef6ff;
}
.operation-bulk-bar button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
.operation-select-cell {
  text-align: center;
}
.operation-select-cell input {
  width: 18px;
  height: 18px;
  margin: 0;
}
.settlement-import-form {
  grid-template-columns: minmax(220px, 0.45fr) minmax(280px, 1fr) auto;
}
.boq-scope-filter {
  display: grid;
  grid-template-columns: auto minmax(220px, 360px);
  align-items: center;
  justify-content: start;
  gap: 10px;
  color: #17324d;
  font-weight: 700;
}
.boq-scope-filter select {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  padding: 0 10px;
}
.explorer-toolbar {
  display: grid;
  grid-template-columns: auto auto auto minmax(160px, 1fr) auto auto minmax(220px, 1.2fr) auto auto;
  gap: 8px;
  align-items: center;
  margin: 14px 0;
}
.explorer-toolbar input,
.explorer-toolbar button {
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
}
.explorer-toolbar input {
  min-width: 0;
  padding: 0 11px;
  color: var(--ink);
}
.explorer-toolbar button {
  padding: 0 12px;
  color: var(--blue);
  font-weight: 800;
  cursor: pointer;
}
.explorer-toolbar button:hover {
  border-color: var(--blue);
  background: #f1f7fc;
}
.explorer-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin: 6px 0 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
}
.explorer-breadcrumb button {
  border: 0;
  background: transparent;
  color: var(--blue-dark);
  font-weight: 800;
  cursor: pointer;
}
.local-agent-panel {
  display: grid;
  gap: 8px;
  margin: 8px 0 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid #64748b;
  border-radius: 8px;
  background: #f8fafc;
  color: #34495e;
}
.local-agent-panel.online {
  border-left-color: #147a46;
  background: #f4fbf7;
}
.local-agent-panel.offline {
  border-left-color: #b42318;
  background: #fff7f5;
}
.local-agent-panel.checking {
  border-left-color: var(--gold);
}
.local-agent-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}
.local-agent-panel strong,
.local-agent-panel span,
.local-agent-panel small,
.local-agent-panel em {
  display: block;
}
.local-agent-panel strong {
  color: var(--blue-dark);
}
.local-agent-panel span,
.local-agent-panel small {
  color: #48627d;
  line-height: 1.5;
}
.local-agent-panel em {
  padding: 4px 8px;
  border-radius: 999px;
  background: #e8f1fb;
  color: var(--blue-dark);
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
}
.local-agent-metrics,
.local-agent-dirs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.local-agent-metrics span,
.local-agent-dirs span {
  padding: 4px 8px;
  border: 1px solid #d6e1ec;
  border-radius: 999px;
  background: #ffffff;
  font-size: 12px;
}
.local-agent-dirs strong {
  flex-basis: 100%;
}
.explorer-shell {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.explorer-tree {
  min-width: 0;
  padding: 10px;
  overflow: auto;
  border-right: 1px solid var(--line);
  background: #f8fafc;
}
.tree-row {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 36px;
  padding: 7px 10px;
  padding-left: calc(10px + var(--depth-offset, 0px));
  border-radius: 6px;
  color: #34495e;
  cursor: pointer;
}
.tree-row:hover,
.tree-row.active,
.tree-row.drag-over {
  background: #e8f1fb;
  color: var(--blue-dark);
}
.tree-icon {
  flex: 0 0 auto;
  color: var(--gold);
}
.explorer-main {
  min-width: 0;
  padding: 12px;
  background: white;
}
.explorer-main.drag-over {
  outline: 2px dashed var(--blue);
  outline-offset: -8px;
  background: #eff6ff;
}
.explorer-main-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
  color: var(--muted);
}
.explorer-main-head strong {
  color: var(--ink);
}
.explorer-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}
.explorer-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.explorer-card:hover,
.explorer-card.drag-over {
  border-color: var(--blue);
  box-shadow: 0 8px 18px rgba(16, 42, 67, .08);
}
.folder-card {
  cursor: pointer;
  background: #fbfdff;
}
.explorer-card strong,
.explorer-card span,
.explorer-card small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
}
.explorer-card strong {
  margin-bottom: 8px;
  white-space: nowrap;
  color: var(--blue-dark);
}
.storage-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 6px;
  border-radius: 999px;
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  vertical-align: middle;
}
.storage-badge.local {
  background: #dcfce7;
  color: #166534;
}
.storage-badge.backend {
  background: #e2e8f0;
  color: #334155;
}
.explorer-card span {
  margin-bottom: 6px;
  color: #34495e;
}
.explorer-card small {
  color: var(--muted);
  line-height: 1.5;
}
.explorer-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.file-context-menu {
  position: fixed;
  z-index: 60;
  width: 180px;
  padding: 8px;
  border: 1px solid #b9c9da;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .18);
}
.file-context-menu button {
  display: block;
  width: 100%;
  min-height: 34px;
  margin: 0 0 6px;
  text-align: left;
}
.file-context-menu button:last-child {
  margin-bottom: 0;
}
.file-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.file-detail-grid > div {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.file-detail-grid .wide {
  grid-column: 1 / -1;
}
.file-detail-grid strong,
.file-detail-grid span {
  display: block;
}
.file-detail-grid strong {
  margin-bottom: 6px;
  color: var(--blue-dark);
}
.file-detail-grid span {
  overflow-wrap: anywhere;
  color: #34495e;
  line-height: 1.55;
}
.file-path-text {
  font-family: Consolas, "Courier New", monospace;
  font-size: 13px;
}
.hidden-field {
  display: none !important;
}
.explorer-empty {
  grid-column: 1 / -1;
  padding: 42px 16px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.admin-page .workspace {
  background: #f5f7fb;
}
.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.admin-grid > [data-admin-view]:not([hidden]) {
  grid-column: 1 / -1;
}
.admin-panel {
  margin-top: 16px;
  background: white;
}
.admin-command-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 10px 0 16px;
}
.admin-command-bar button {
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}
.admin-command-bar button:hover {
  border-color: #1f5f99;
  background: #eff6ff;
}
.admin-command-bar button.danger-command,
button.danger-command {
  border-color: #b42318;
  background: #b42318;
  color: #ffffff;
}
.admin-command-bar button.danger-command:hover,
button.danger-command:hover {
  background: #8f1b13;
}
.admin-command-bar button:disabled,
button.danger-command:disabled {
  border-color: #cbd5e1;
  background: #e5e7eb;
  color: #64748b;
  cursor: not-allowed;
}
.command-summary {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 12px;
  color: var(--muted);
  font-weight: 700;
}
.compact-list {
  display: grid;
  gap: 6px;
  max-height: 240px;
  margin: 12px 0;
  padding: 12px;
  overflow: auto;
  border: 1px solid var(--line);
  background: #f8fafc;
}
.module-subnav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin: 8px 0 18px;
}
.module-subnav button {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}
.module-subnav button:hover {
  border-color: #1f5f99;
  background: #eff6ff;
}
.module-subnav button.active {
  border-color: #1f5f99;
  background: #1f5f99;
  color: #ffffff;
  box-shadow: 0 6px 14px rgba(31, 95, 153, 0.18);
}
[data-module-subview][hidden] {
  display: none !important;
}
.storage-bridge-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 10px 0 14px;
}
.storage-bridge-summary {
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid #64748b;
  border-radius: 8px;
  background: #f8fafc;
}
.storage-bridge-summary strong,
.storage-bridge-summary span,
.storage-bridge-summary small {
  display: block;
}
.storage-bridge-summary strong {
  color: var(--blue-dark);
  font-size: 16px;
}
.storage-bridge-summary span,
.storage-bridge-summary small {
  color: #48627d;
  line-height: 1.5;
}
.storage-bridge-summary.online {
  border-left-color: #147a46;
  background: #f4fbf7;
}
.storage-bridge-summary.offline {
  border-left-color: #b42318;
  background: #fff7f5;
}
.storage-bridge-summary.checking {
  border-left-color: var(--gold);
}
.storage-bridge-actions {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.storage-bridge-actions button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  cursor: pointer;
}
.storage-bridge-actions button:hover {
  border-color: var(--blue);
  background: #eff6ff;
}
.spool-table {
  margin-bottom: 16px;
}
.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e8f1fb;
  color: var(--blue-dark);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}
.status-pill.spool-synced {
  background: #e7f6ed;
  color: #147a46;
}
.status-pill.spool-pending {
  background: #fff7df;
  color: #8a5a00;
}
.status-pill.spool-failed,
.status-pill.spool-expired {
  background: #fff0ed;
  color: #b42318;
}
.account-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}
.account-status-pill.enabled {
  background: #e9f7ef;
  color: #137a45;
}
.account-status-pill.disabled {
  background: #eef1f5;
  color: #667085;
}
.data-table tr.account-row-enabled td:first-child {
  border-left: 4px solid #75b985;
}
.data-table tr.account-row-enabled td {
  background: #fbfffc;
}
.data-table tr.account-row-disabled td:first-child {
  border-left: 4px solid #b7bec8;
}
.data-table tr.account-row-disabled td {
  background: #f5f6f8;
  color: #7a8494;
}
.data-table tr.account-row-disabled .table-action {
  opacity: .82;
}
.permission-entry-note {
  margin-bottom: 14px;
}
.dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  justify-content: flex-end;
  background: rgba(15, 23, 42, .34);
}
.admin-dialog {
  width: min(720px, 100%);
  height: 100%;
  padding: 24px;
  overflow: auto;
  background: #ffffff;
  box-shadow: -16px 0 36px rgba(15, 23, 42, .2);
}
.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.dialog-head h3 {
  margin: 2px 0 8px;
  font-size: 24px;
  color: var(--blue-dark);
}
.dialog-head span,
.dialog-summary span {
  display: block;
  color: var(--muted);
  line-height: 1.6;
}
.dialog-summary small {
  display: block;
  margin-top: 6px;
  color: #475467;
  line-height: 1.6;
}
.icon-close {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--blue-dark);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.dialog-form {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 0;
  border: 0;
  background: transparent;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.form-grid .full-row {
  grid-column: 1 / -1;
}
.dialog-subbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 18px 0 10px;
}
.dialog-subbar h4 {
  margin: 0;
  color: var(--blue-dark);
  font-size: 18px;
}
.workflow-template-dialog {
  width: min(980px, 100%);
}
.template-node-list {
  display: grid;
  gap: 10px;
}
.template-node-row {
  display: grid;
  grid-template-columns: 1.35fr .85fr .95fr .7fr auto;
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.workflow-initiator-note {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 12px 14px;
  border: 1px solid #bbf7d0;
  border-left: 4px solid #16a34a;
  border-radius: 8px;
  background: #f0fdf4;
}
.workflow-initiator-note strong {
  color: #166534;
  white-space: nowrap;
}
.workflow-initiator-note span {
  color: #344054;
  line-height: 1.5;
}
.workflow-role-field,
.workflow-user-field {
  grid-column: 1 / -1;
}
.template-node-row[data-approver-source="user"] .workflow-role-field,
.template-node-row[data-approver-source="role"] .workflow-user-field,
.template-node-row[data-approver-source="project_role"] .workflow-user-field,
.template-node-row[data-approver-source="system"] .workflow-role-field,
.template-node-row[data-approver-source="system"] .workflow-user-field {
  display: none;
}
.workflow-check-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.workflow-user-grid {
  max-height: 190px;
  overflow: auto;
  padding-right: 4px;
}
.workflow-check-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid #cfd8e3;
  border-radius: 6px;
  background: #ffffff;
  color: #17324d;
  font-size: 13px;
  font-weight: 700;
}
.workflow-check-chip input {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}
.workflow-check-chip span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.workflow-user-field input[type="search"] {
  width: 100%;
  min-height: 38px;
  margin-top: 8px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  font: inherit;
}
.dialog-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.check-inline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  margin-top: 6px;
  color: var(--ink);
  font-weight: 600;
}
.check-inline input {
  width: auto;
}
.finance-node-config {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.finance-node-config > strong {
  color: var(--blue-dark);
  font-size: 15px;
}
.finance-node-config > span {
  color: var(--muted);
  line-height: 1.6;
}
.finance-node-grid {
  display: grid;
  gap: 12px;
}
.finance-node-row {
  display: grid;
  grid-template-columns: minmax(140px, 1.2fr) minmax(110px, .8fr) minmax(120px, .9fr) minmax(160px, 1.1fr) minmax(180px, 1.4fr) minmax(90px, .7fr);
  gap: 10px;
  align-items: end;
  padding: 10px;
  border: 1px solid #d9e2ef;
  border-radius: 8px;
  background: #ffffff;
}
.finance-node-row select[multiple] {
  min-height: 72px;
}
.finance-attachment-panel,
.settlement-upload-panel {
  grid-column: 1 / -1;
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 14px;
  border: 1px solid #bdd3e8;
  border-radius: 8px;
  background: #f3f8fd;
}
.finance-attachment-head,
.settlement-upload-head {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.finance-attachment-head strong,
.settlement-upload-head strong {
  color: var(--blue-dark);
  font-size: 15px;
}
.finance-attachment-head span,
.settlement-upload-head span {
  color: var(--muted);
  font-weight: 500;
  line-height: 1.6;
}
.finance-upload-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.finance-upload-field,
.finance-existing-link {
  margin: 0;
  color: #263f59;
}
.finance-upload-field input[type="file"] {
  min-height: 44px;
  padding: 9px 10px;
  border-style: dashed;
  background: #ffffff;
  cursor: pointer;
}
.finance-upload-field input[type="file"]::file-selector-button {
  margin-right: 10px;
  padding: 7px 12px;
  border: 1px solid #b7c7d9;
  border-radius: 6px;
  background: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  cursor: pointer;
}
.finance-existing-link {
  display: block;
}
.operation-signal-dialog {
  width: min(920px, 94vw);
}
.operation-detail-dialog {
  width: min(1040px, 96vw);
}
.operation-signal-form {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.operation-signal-form .wide {
  grid-column: 1 / -1;
}
.operation-detail-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.operation-detail-kpis article {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.operation-detail-kpis span,
.operation-detail-kpis strong {
  display: block;
}
.operation-detail-kpis span {
  color: var(--muted);
  font-size: 12px;
}
.operation-detail-kpis strong {
  margin-top: 5px;
  color: var(--blue-dark);
  font-size: 20px;
  word-break: break-all;
}
.operation-detail-actions {
  margin: 12px 0;
}
.operation-detail-sections {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}
.operation-detail-section {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}
.operation-detail-section h4 {
  margin: 0 0 8px;
  color: var(--blue-dark);
}
.detail-list {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.detail-list li {
  padding: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
}
.detail-list strong,
.detail-list span,
.detail-list small {
  display: block;
}
.detail-list span,
.detail-list small {
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.55;
}
.detail-list-actions {
  margin-top: 8px;
}
.file-preview-dialog {
  width: min(1120px, calc(100vw - 40px));
}
.file-preview-body {
  min-height: 420px;
  max-height: 68vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.file-preview-image {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
  background: #ffffff;
}
.file-preview-frame {
  display: block;
  width: 100%;
  height: 68vh;
  border: 0;
  background: #ffffff;
}
.file-preview-text {
  min-height: 420px;
  margin: 0;
  padding: 16px;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--blue-dark);
  background: #ffffff;
}
.file-preview-office {
  min-height: 420px;
  padding: 18px;
  color: var(--blue-dark);
  background: #ffffff;
}
.file-preview-office p {
  margin: 0 0 10px;
  line-height: 1.72;
}
.office-preview-sheet {
  margin-bottom: 22px;
}
.office-preview-sheet h4 {
  margin: 0 0 10px;
  font-size: 16px;
}
.office-preview-table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  background: #ffffff;
}
.office-preview-table td {
  min-width: 96px;
  max-width: 320px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  vertical-align: top;
  line-height: 1.5;
  word-break: break-word;
}
.office-preview-note {
  margin-top: 12px;
  color: var(--muted);
}
.file-preview-empty {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  min-height: 420px;
  padding: 24px;
  text-align: center;
  color: var(--muted);
}
.file-preview-empty strong {
  color: var(--blue-dark);
  font-size: 20px;
}
.operation-detail-forms {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}
.operation-detail-form {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.operation-detail-form .wide {
  grid-column: span 2;
}
.operation-detail-form .full {
  grid-column: 1 / -1;
}
.dialog-summary {
  grid-column: 1 / -1;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
}
.dialog-summary strong {
  display: block;
  margin-bottom: 4px;
  color: var(--blue-dark);
}
.choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.choice-grid strong {
  grid-column: 1 / -1;
  color: var(--blue-dark);
}
.choice-grid label {
  min-height: 32px;
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-weight: 600;
}
.choice-grid input {
  width: auto;
  min-height: auto;
}
.dialog-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.dialog-actions button {
  min-width: 96px;
}
.dialog-actions .secondary-action {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--blue-dark);
}
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}
.section-title h2 {
  margin: 0;
}
.inline-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 10px;
  align-items: end;
  margin: 10px 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.inline-form.compact-form {
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
}
#adminCreateFolderForm {
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
}
#adminCreateFolderForm.dialog-form,
.inline-form.dialog-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 0;
  border: 0;
  background: transparent;
}
.permission-form {
  grid-template-columns: repeat(2, minmax(0, 1fr)) auto;
}
.inline-form label {
  margin: 0;
  color: #263f59;
  font-size: 13px;
}
.inline-form label.wide {
  grid-column: span 2;
}
.inline-form label.ai-toggle-field {
  grid-column: span 2;
}
.inline-form label.permission-field {
  grid-column: 1 / -1;
}
.ai-toggle-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.ai-toggle-group button {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--blue-dark);
  font-weight: 800;
  cursor: pointer;
}
.ai-toggle-group button:hover {
  border-color: var(--blue);
  background: #eff6ff;
}
.ai-toggle-group button.active {
  border-color: #0f4f84;
  background: #1f5f99;
  color: #ffffff;
}
.permission-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.check-item {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
  font-weight: 600;
}
.check-item input {
  width: auto;
  margin: 0;
}
.check-item-inherited {
  background: #f2f4f7;
  color: #8a94a6;
  border-color: #d5dbe5;
  cursor: not-allowed;
}
.check-item-inherited input {
  cursor: not-allowed;
}
.check-item-inherited span::after {
  content: "（角色默认）";
  margin-left: 4px;
  color: #98a2b3;
  font-size: 12px;
  font-weight: 700;
}
.inline-form input,
.inline-form select {
  margin-top: 6px;
  padding: 10px;
  background: white;
}
.inline-form button,
.table-action {
  min-height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 6px;
  background: var(--blue);
  color: white;
  font-weight: 800;
  cursor: pointer;
}
.table-action {
  min-height: 32px;
  background: #147a46;
  margin: 2px 4px 2px 0;
}
.table-action.danger {
  background: #b42318;
}
.table-action.secondary-action {
  border: 1px solid #0f4f84;
  background: #1f5f99;
  color: #ffffff;
}
.table-action.secondary-action:hover {
  background: #113b60;
  color: #ffffff;
}
.inline-form .dialog-actions .secondary-action {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--blue-dark);
}
.table-shell {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}
.folder-table {
  margin-bottom: 16px;
}
.subsection-title {
  margin: 12px 0 10px;
  color: #17324d;
  font-size: 16px;
}
.data-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 14px;
}
.data-table th,
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.data-table th {
  position: sticky;
  top: 0;
  background: #eef3f8;
  color: #17324d;
  font-weight: 800;
}
.data-table td {
  color: #34495e;
  line-height: 1.5;
}
.data-table button {
  min-height: 30px;
  margin: 2px 4px 2px 0;
  padding: 0 10px;
  border: 1px solid #b9c9da;
  border-radius: 6px;
  background: #f8fbff;
  color: var(--blue);
  font-weight: 800;
  cursor: pointer;
}
.data-table button:hover {
  border-color: var(--blue);
  background: #eef6ff;
}
.data-table tr:last-child td {
  border-bottom: 0;
}
.empty-cell {
  color: var(--muted);
  text-align: center !important;
}
.workflow-filter-bar button.active {
  background: var(--blue);
  color: #ffffff;
  border-color: var(--blue);
}
.workflow-progress {
  display: grid;
  grid-template-columns: 44px minmax(120px, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 170px;
  font-weight: 800;
  color: #17324d;
}
.workflow-progress i {
  display: block;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #d8e3ee;
}
.workflow-progress b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
}
.workflow-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eaf2fb;
  color: #0f4f84;
  font-weight: 800;
}
.workflow-badge.done {
  background: #e8f6ee;
  color: #137a46;
}
.workflow-badge.revision {
  background: #fff5df;
  color: #945f00;
}
.workflow-badge.rejected {
  background: #fdecec;
  color: #b42318;
}
.workflow-due {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #344054;
  font-weight: 800;
}
.workflow-due.overdue {
  background: #fdecec;
  color: #b42318;
}
.workflow-engine-panel {
  display: grid;
  gap: 14px;
  margin: 14px 0;
}
.workflow-engine-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 14px;
}
.workflow-engine-grid h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: var(--blue-dark);
}
.archive-flow-row td {
  background: #f8fbff;
  border-top: 0;
}
.archive-flow-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  padding: 8px 10px;
  color: #344054;
}
.archive-flow-title {
  font-weight: 900;
  color: var(--blue-dark);
}
.archive-flow-progress .workflow-progress {
  grid-template-columns: auto minmax(100px, 180px);
  min-width: 150px;
}
.archive-dialog textarea {
  min-height: 88px;
  resize: vertical;
}
.workflow-dialog textarea {
  width: 100%;
  min-height: 92px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  resize: vertical;
}
.workflow-hint {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  color: #12385b;
  background: #eff6ff;
}
.workflow-summary {
  display: grid;
  grid-template-columns: 120px minmax(180px, 1fr) repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
}
.workflow-summary div {
  min-width: 0;
}
.workflow-summary strong,
.workflow-summary span {
  display: block;
}
.workflow-node-list {
  display: grid;
  gap: 10px;
}
.workflow-node {
  padding: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid #9db4ca;
  border-radius: 8px;
  background: #ffffff;
}
.workflow-node-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.workflow-node-head > div {
  min-width: 0;
}
.workflow-remind-btn {
  flex: 0 0 auto;
  white-space: nowrap;
}
.workflow-node strong,
.workflow-node span,
.workflow-node small {
  display: block;
}
.workflow-node.done {
  border-left-color: #137a46;
}
.workflow-node.pending {
  border-left-color: var(--blue);
}
.workflow-node.revision {
  border-left-color: #c47a00;
}
.workflow-node.rejected {
  border-left-color: #b42318;
}
.workflow-node.overdue {
  background: #fff7f7;
  border-left-color: #b42318;
}
.workflow-action-list {
  margin: 0;
  padding-left: 18px;
}
.workflow-action-list li {
  margin: 8px 0;
}
.inline-form.dialog-form,
.inline-form.permission-form.dialog-form,
.inline-form.settlement-form.dialog-form,
.inline-form.task-form.dialog-form,
.inline-form.operation-form.dialog-form,
#adminCreateFolderForm.dialog-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .target-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav { display: none; }
  .hero { min-height: 560px; }
  .service-grid, .band, .login-shell, .workspace-page, .kpi-grid, .module-grid, .about-layout, .process-grid, .partner-band, .login-modules, .module-list, .admin-grid, .admin-command-bar, .storage-bridge-panel, .storage-bridge-actions, .inline-form, .inline-form.compact-form, .inline-form.dialog-form, #adminCreateFolderForm, .permission-form, .permission-grid, .task-form, .task-detail-grid, .settlement-kpis, .settlement-form, .settlement-import-form, .boq-scope-filter, .operation-filter-bar, .operation-group-summary, .explorer-toolbar, .explorer-shell, .file-detail-grid, .operation-detail-kpis, .operation-detail-sections, .operation-detail-form, .finance-upload-grid, .workflow-summary, .workflow-engine-grid, .form-grid, .template-node-row, .tools-grid, .tool-note-grid, .tool-meta {
    grid-template-columns: 1fr;
  }
  .admin-dialog {
    width: 100%;
    padding: 18px;
  }
  .dialog-actions {
    justify-content: stretch;
  }
  .dialog-actions button {
    flex: 1;
  }
  .explorer-tree {
    max-height: 240px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .explorer-main-head {
    flex-direction: column;
  }
  .explorer-items {
    grid-template-columns: 1fr;
  }
  .workspace-top {
    align-items: flex-start;
    flex-direction: column;
  }
  .workspace-actions,
  .workspace-switcher {
    justify-content: flex-start;
    max-width: 100%;
  }
  .inline-form label.wide {
    grid-column: auto;
  }
  .operation-detail-form .wide {
    grid-column: auto;
  }
  .operation-detail-form .full {
    grid-column: auto;
  }
  .partner-actions { justify-content: flex-start; }
  .sidebar { position: static; }
  .footer {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
  .footer-copyright {
    grid-column: auto;
    justify-self: center;
    white-space: normal;
  }
  .footer-beian {
    grid-column: auto;
    justify-self: center;
    justify-content: center;
  }
  .footer-site {
    grid-column: auto;
    justify-self: center;
    text-align: center;
  }
}

@media (max-width: 600px) {
  .target-summary-grid {
    grid-template-columns: 1fr;
  }
}
