/* 统一「提交 XX」对话框样式 — 配合 macros/submit_entity_modal.html */

.iar-submit-md-preview,
.sb-md-preview {
  word-break: break-word;
  white-space: normal;
  line-height: 1.65;
  color: #333;
}

.iar-submit-md-preview img,
.sb-md-preview img,
.iar-md-preview-img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0.75rem 0;
}

.iar-submit-md-preview p,
.sb-md-preview p {
  margin-bottom: 0.75rem;
}

.iar-submit-md-preview p:last-child,
.sb-md-preview p:last-child {
  margin-bottom: 0;
}

.iar-submit-md-preview a,
.iar-submit-md-preview .iar-submit-md-link,
.iar-submit-md-preview .sb-md-link,
.sb-md-preview a,
.sb-md-preview .sb-md-link {
  color: #0d6efd;
  text-decoration: underline;
}

.iar-submit-history-panel,
.sb-history-panel {
  max-height: 220px;
  overflow-y: auto;
}

.iar-submit-history-entry,
.sb-history-entry {
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.5rem;
  background-color: #fff;
}

.iar-submit-history-entry:last-child,
.sb-history-entry:last-child {
  margin-bottom: 0;
}

.iar-submit-entity-toolbar .btn {
  margin-bottom: 0;
}

.iar-submit-attach-list {
  min-height: 2.5rem;
  max-height: 160px;
  overflow-y: auto;
}

.iar-submit-attach-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid #dee2e6;
  border-radius: 0.375rem;
  background: #fff;
  margin-bottom: 0.35rem;
}

.iar-submit-attach-item:last-child {
  margin-bottom: 0;
}

.iar-submit-attach-item .iar-submit-attach-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.875rem;
}

.iar-submit-attach-item .iar-submit-attach-meta {
  flex-shrink: 0;
  color: #6c757d;
  font-size: 0.75rem;
}
