/* 衡策业财（业财 AI 审核、对账与经营问数）：与 agent-shell .theme-finance 完全同色系 */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #f2f3f8;
  color: #111827;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 13.5px;
  line-height: 1.55;
}

.fin-wb-modebar {
  --ga-surface: #ffffff;
  --ga-subtle: #e9ecf4;
  --ga-hover: #eff1f8;
  --ga-line: rgba(15, 23, 42, 0.08);
  --ga-line-strong: rgba(15, 23, 42, 0.14);
  --ga-ink: #111827;
  --ga-ink-2: #475569;
  --ga-ink-3: #64748b;
  position: fixed;
  top: 38px;
  left: 0;
  right: 0;
  height: 50px;
  z-index: 2147481000;
  background: #ffffff;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

body.gf-mode-workbench {
  padding-top: 88px !important;
}

body.gf-mode-agent .fin-wb-shell,
body.gf-mode-agent .fin-wb-modebar {
  display: none !important;
}

.fin-wb-shell {
  min-height: calc(100vh - 88px);
  padding: 20px 24px 48px;
  max-width: 1280px;
  margin: 0 auto;
}

.fin-wb-head {
  margin-bottom: 18px;
}

.fin-wb-head h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: #111827;
}

.fin-wb-head p {
  margin: 4px 0 0;
  font-size: 13px;
  color: #475569;
}

.fin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.fin-kpi-card {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  padding: 14px 16px;
}

.fin-kpi-card .k-label {
  font-size: 12px;
  color: #64748b;
  font-weight: 500;
}

.fin-kpi-card .k-val {
  margin-top: 6px;
  font-size: 22px;
  font-weight: 700;
  color: #111827;
  font-variant-numeric: tabular-nums;
}

.fin-kpi-card .k-val.accent {
  color: #3730a3;
}

.fin-kpi-card .k-val.ok {
  color: #047857;
}

.fin-kpi-card .k-val.bad {
  color: #dc2626;
}

.fin-kpi-card .k-sub {
  margin-top: 4px;
  font-size: 12px;
  color: #64748b;
}

.fin-wb-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  margin-bottom: 16px;
  overflow-x: auto;
}

.fin-wb-tab {
  appearance: none;
  border: 0;
  background: transparent;
  color: #475569;
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 14px;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

.fin-wb-tab.active {
  color: #3730a3;
  border-bottom-color: #3730a3;
}

.fin-wb-card {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 14px;
  padding: 18px 20px;
  margin-bottom: 14px;
}

.fin-wb-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.fin-wb-card-head h2 {
  margin: 0;
  font-size: 15.5px;
  font-weight: 700;
}

.fin-wb-card-head p {
  margin: 3px 0 0;
  font-size: 12.5px;
  color: #64748b;
}

.fin-wb-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.fin-wb-table th,
.fin-wb-table td {
  padding: 9px 10px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  text-align: left;
  vertical-align: top;
}

.fin-wb-table th {
  background: #f2f3f8;
  color: #475569;
  font-weight: 600;
  font-size: 11.5px;
}

.fin-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
}

.fin-pill.ok {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.fin-pill.bad {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.fin-pill.warn {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

.fin-pill.indigo {
  background: #eef2ff;
  color: #3730a3;
  border: 1px solid #c7d2fe;
}

.fin-wb-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.fin-wb-btn {
  appearance: none;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  color: #111827;
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 8px;
  cursor: pointer;
}

.fin-wb-btn.primary {
  background: #3730a3;
  border-color: #3730a3;
  color: #ffffff;
}

.fin-wb-btn.primary:hover:not(:disabled) {
  background: #312e81;
}

.fin-wb-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.fin-log-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.fin-log-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: #f2f3f8;
  border-radius: 10px;
  font-size: 12.5px;
}

@media (max-width: 900px) {
  .fin-wb-shell {
    padding: 14px 12px 36px;
  }
  .fin-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
