#appShell .dt-wrap {
  display: grid;
  grid-template-columns: minmax(200px, 2.5fr) minmax(280px, 3fr) minmax(320px, 4.5fr);
  gap: 12px;
  align-items: start;
}

#appShell .dt-col {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px;
  min-height: 460px;
}

#appShell .dt-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--border);
}

#appShell .dt-head--sub {
  margin-top: 18px;
}

#appShell .dt-muted { font-size: 12px; font-weight: 400; color: #98a2b3; }

#appShell .dt-list { display: flex; flex-direction: column; gap: 2px; }

#appShell .dt-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  color: #344054;
}

#appShell .dt-item:hover { background: #f5f7fa; }
#appShell .dt-item.is-active { background: var(--primary-light); }
#appShell .dt-item.is-active .dt-name { color: var(--primary-hover); font-weight: 600; }
#appShell .dt-item.is-off .dt-name { color: #98a2b3; text-decoration: line-through; }

#appShell .dt-index {
  width: 16px;
  flex: 0 0 auto;
  font-size: 12px;
  color: #98a2b3;
  text-align: center;
}

#appShell .dt-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#appShell .dt-tag {
  flex: 0 0 auto;
  font-size: 11px;
  padding: 1px 4px;
  border-radius: 4px;
  background: #f2f4f7;
  color: #475467;
}

#appShell .dt-item.is-active .dt-tag { background: #fff; color: var(--primary-hover); }

#appShell .dt-switch {
  width: 26px;
  height: 14px;
  border-radius: 7px;
  background: #d0d5dd;
  flex: 0 0 auto;
  position: relative;
  transition: background 0.15s;
}

#appShell .dt-switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.2);
  transition: transform 0.15s;
}

#appShell .dt-switch.is-on { background: var(--primary); }
#appShell .dt-switch.is-on::after { transform: translateX(12px); }

#appShell .dt-ops {
  display: flex;
  gap: 1px;
  flex: 0 0 auto;
  opacity: 0;
  min-width: 56px;
  justify-content: flex-end;
}

#appShell .dt-item:hover .dt-ops,
#appShell .dt-item.is-active .dt-ops { opacity: 1; }

#appShell .dt-op {
  width: 18px;
  height: 18px;
  line-height: 16px;
  text-align: center;
  border: 0;
  padding: 0;
  background: transparent;
  color: #667085;
  cursor: pointer;
  border-radius: 4px;
  font-size: 12px;
}

#appShell .dt-op:hover { background: #e4e7ec; color: #101828; }

#appShell .dt-add {
  width: 100%;
  margin-top: 10px;
  border: 1px dashed var(--border);
  background: transparent;
  border-radius: 6px;
  height: 30px;
  font-size: 12px;
  color: #475467;
  cursor: pointer;
}

#appShell .dt-add:hover { border-color: var(--primary); color: var(--primary); }

#appShell .dt-field { margin-top: 8px; }

#appShell .dt-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

#appShell .dt-grid > .dt-field { margin-top: 0; }

#appShell .dt-field--wide { grid-column: 1 / -1; }

#appShell .dt-field > label:not(.dt-check) {
  display: block;
  font-size: 11px;
  color: #667085;
  margin-bottom: 3px;
  font-weight: 400;
}

#appShell .dt-field input,
#appShell .dt-field select {
  width: 100%;
  height: 30px;
  font-size: 12px;
  padding: 2px 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  box-sizing: border-box;
}

#appShell .dt-field textarea {
  width: 100%;
  min-height: 64px;
  font-size: 12px;
  padding: 4px 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  box-sizing: border-box;
  resize: vertical;
  font-family: inherit;
}

#appShell .dt-body-text {
  min-height: 300px;
  line-height: 1.7;
  font-size: 13px;
}

#appShell .dt-check {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 400;
  margin: 0;
  padding: 3px 7px;
  border: 1px solid var(--border);
  border-radius: 14px;
  cursor: pointer;
  color: #475467;
}

#appShell .dt-check input {
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  margin: 0;
  padding: 0;
}

#appShell .dt-check.is-on { border-color: var(--primary); color: var(--primary-hover); background: var(--primary-light); }

#appShell .dt-checks { display: flex; flex-wrap: wrap; gap: 4px; }

#appShell .dt-hint {
  font-size: 11px;
  color: #98a2b3;
  margin: 6px 0 0;
  line-height: 1.5;
}

#appShell .dt-empty {
  padding: 40px 12px;
  text-align: center;
  font-size: 13px;
  color: #98a2b3;
}

#appShell .dt-settings {
  margin-top: 16px;
  border-top: 1px solid var(--border);
  padding-top: 10px;
}

#appShell .dt-settings summary { font-size: 12px; color: #475467; cursor: pointer; }

#appShell .dt-toolbar-select {
  height: 30px;
  max-width: 200px;
  font-size: 12px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
}

#appShell .dt-var {
  margin-top: 6px;
  height: 28px;
  font-size: 12px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  max-width: 160px;
}

/* 生成方案弹窗里的版式选择，弹窗在 #appShell 外面，选择器不能带前缀 */
.proposal-doc-layout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 24px;
}

.proposal-doc-layout[hidden] { display: none; }

.proposal-doc-layout select {
  height: 30px;
  font-size: 12px;
  max-width: 300px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
}
