/* 控制台 · 发票管理工作台样式（仅作用于本工作台与发票弹窗，不改动站内其它组件） */

.inv-status {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.inv-status-pending { color: #b45309; background: #dce8e9; }
.inv-status-issued { color: #047857; background: #d1fae5; }
.inv-status-rejected { color: #b91c1c; background: #fee2e2; }

.inv-ops { display: flex; gap: 6px; flex-wrap: wrap; }

.inv-modal {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.inv-modal-scrim {
  position: absolute;
  inset: 0;
  background: rgba(16,37,41, 0.48);
  backdrop-filter: blur(2px);
}
.inv-modal-card {
  position: relative;
  width: min(680px, 100%);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(16,37,41, 0.28);
  overflow: hidden;
}
.inv-modal-wide { width: min(860px, 100%); }
.inv-modal-head {
  padding: 18px 22px;
  border-bottom: 1px solid #eef1f6;
}
.inv-modal-head h4 { margin: 0; font-size: 17px; color: #122326; }
.inv-modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #6b7280;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.inv-modal-close:hover { background: #f3f4f6; color: #122326; }
.inv-modal-body { padding: 18px 22px; overflow: auto; }
.inv-modal-foot {
  padding: 14px 22px;
  border-top: 1px solid #eef1f6;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  background: #fafbfc;
}

.inv-form .inv-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 14px;
}
.inv-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: #475569;
}
.inv-form label.span2 { grid-column: span 2; }
.inv-form .inv-static {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  border: 1px solid #e5e9f1;
  border-radius: 9px;
  font-size: 14px;
  color: #122326;
  background: #f9fbfb;
  font-weight: 600;
}
.inv-form input,
.inv-form select,
.inv-form textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  border: 1px solid #d9dee8;
  border-radius: 9px;
  font-size: 14px;
  color: #122326;
  background: #fff;
  outline: none;
  font-family: inherit;
}
.inv-form input:focus,
.inv-form select:focus,
.inv-form textarea:focus { border-color: #0e7c86; box-shadow: 0 0 0 3px rgba(14,124,134, 0.12); }
.inv-tip {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin: 14px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f4f8f8;
  color: #11626d;
  font-size: 12.5px;
  line-height: 1.6;
}
.inv-tip .icon { flex: none; margin-top: 2px; }
.inv-error { min-height: 18px; margin: 8px 0 0; color: #dc2626; font-size: 13px; }

.inv-order-row { display: flex; gap: 8px; align-items: center; }
.inv-order-row input { flex: 1; min-width: 0; }
.inv-order-row .act-btn { flex: none; white-space: nowrap; }
.inv-order-hint { font-size: 12px; line-height: 1.5; color: #8a94a6; }

.inv-modal-stack { z-index: 10000; }
.inv-order-search {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  margin-bottom: 10px;
  border: 1px solid #d9dee8;
  border-radius: 9px;
  font-size: 14px;
  outline: none;
  font-family: inherit;
}
.inv-order-search:focus { border-color: #0e7c86; box-shadow: 0 0 0 3px rgba(14,124,134, 0.12); }
.inv-order-list { max-height: 340px; overflow: auto; border: 1px solid #eef1f6; border-radius: 10px; }
.inv-order-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid #f3f7f7;
  cursor: pointer;
}
.inv-order-item:last-child { border-bottom: 0; }
.inv-order-item:hover { background: #f9fbfb; }
.inv-order-item input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #0e7c86;
}
.inv-order-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.inv-order-main strong { font-size: 13px; color: #122326; }
.inv-order-main span {
  font-size: 12px;
  color: #64748b;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.inv-order-amount { font-size: 13px; font-weight: 600; color: #122326; white-space: nowrap; }
.inv-order-date { font-size: 12px; color: #94a3b8; white-space: nowrap; }
.inv-order-empty { padding: 28px 16px; text-align: center; color: #94a3b8; font-size: 13px; }
.inv-picker-summary { margin-right: auto; color: #475569; font-size: 13px; }

.inv-detail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
}
.inv-field { display: flex; flex-direction: column; gap: 3px; padding: 8px 10px; background: #f9fbfb; border-radius: 9px; }
.inv-field.span2 { grid-column: span 2; }
.inv-field span { font-size: 12px; color: #64748b; }
.inv-field strong { font-size: 14px; color: #122326; font-weight: 600; word-break: break-all; }
.inv-note { margin-top: 12px; padding: 10px 12px; background: #f9fbfb; border-radius: 9px; }
.inv-note span { font-size: 12px; color: #64748b; }
.inv-note p { margin: 4px 0 0; white-space: pre-wrap; color: #122326; }
.inv-alert {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #fee2e2;
  color: #991b1b;
  font-size: 13px;
}
.inv-file-card {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid #e5e9f1;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.inv-file-main { display: flex; align-items: center; gap: 10px; min-width: 0; }
.inv-file-main .icon { width: 28px; height: 28px; color: #0e7c86; }
.inv-file-main div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.inv-file-main strong { font-size: 14px; color: #122326; word-break: break-all; }
.inv-file-main span { font-size: 12px; color: #64748b; }
.inv-file-ops { display: flex; gap: 8px; }
.inv-img { display: block; max-width: 100%; margin: 0 auto; border-radius: 8px; }

html.inv-modal-open, body.inv-modal-open { overflow: hidden; }

@media (max-width: 720px) {
  .inv-form .inv-grid, .inv-detail { grid-template-columns: 1fr; }
  .inv-form label.span2, .inv-field.span2 { grid-column: span 1; }
  .inv-modal { padding: 10px; }
  .inv-modal-body { padding: 14px; }
}