/* 书架管理：导入、书本管理抽屉、回收站 */
.shelf-actions { display: flex; align-items: center; gap: 12px; }

.import-progress { display: none; margin-top: 16px; }
.import-progress.on { display: block; }
.import-progress .label { font-size: 12.5px; color: var(--ink-2); margin-bottom: 8px; }
.import-progress .track { height: 4px; background: var(--line); border-radius: 2px; overflow: hidden; }
.import-progress .bar { height: 100%; width: 0; background: var(--seal); transition: width 120ms linear; }

.drop-overlay {
  position: fixed; inset: 0; z-index: 9000; display: none; place-items: center;
  background: rgba(18,22,18,.58); padding: 24px;
}
.drop-overlay.on { display: grid; }
.drop-card {
  width: min(420px, 100%); background: var(--surface);
  border: 2px dashed var(--seal); border-radius: 6px;
  padding: 52px 24px; text-align: center;
  font-size: 16px; font-weight: 800; color: var(--ink);
}
.drop-card small { display: block; margin-top: 10px; font-size: 12px; font-weight: 400; color: var(--ink-3); }

/* ---------- 书本管理抽屉 ---------- */
.manage-field { margin-bottom: 16px; }
.manage-field label { display: block; font-size: 12px; color: var(--ink-2); margin-bottom: 7px; }
.manage-field .input { height: 44px; }
.manage-field textarea {
  width: 100%; min-height: 82px; padding: 10px 12px; font: 14px/1.7 var(--ui);
  color: var(--ink); background: var(--page);
  border: 1px solid var(--line); border-radius: var(--r); resize: vertical;
}
.manage-field textarea:focus { outline: none; border-color: var(--seal); }

.detail-list { margin: 22px 0 24px; border-top: 1px solid var(--line); }
.detail-row {
  display: flex; justify-content: space-between; gap: 14px;
  padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 12.5px;
}
.detail-row span:first-child { color: var(--ink-3); flex: none; }
.detail-row span:last-child {
  color: var(--ink-2); text-align: right; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.manage-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.manage-actions .btn { flex: 1; min-width: 118px; border-color: var(--line-2); }

.danger-zone { margin-top: 30px; padding-top: 18px; border-top: 1px solid var(--line); }
.danger-zone h3 { font-size: 13px; font-weight: 800; margin: 0 0 8px; }
.danger-zone p { font-size: 12px; color: var(--ink-3); line-height: 1.85; margin: 0 0 12px; }
.btn-danger { color: var(--danger); border-color: var(--line-2); }
.btn-danger:hover { color: var(--danger); background: var(--seal-soft); border-color: var(--danger); }

.confirm-box {
  display: none; margin-top: 12px; padding: 14px;
  background: var(--seal-soft); border: 1px solid var(--seal); border-radius: var(--r);
}
.confirm-box.on { display: block; }
.confirm-box p { margin: 0 0 12px; font-size: 12.5px; color: var(--ink); line-height: 1.7; }
.confirm-actions { display: flex; gap: 8px; }
.confirm-actions .btn { flex: 1; min-height: 40px; }

/* ---------- 回收站 ---------- */
.trash-section { margin-top: 60px; border-top: 1px solid var(--line); padding-top: 20px; }
.trash-toggle {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px;
  font-size: 13px; font-weight: 800; color: var(--ink); text-align: left;
}
.trash-toggle .count { font-size: 11.5px; font-weight: 400; color: var(--ink-3); }
.trash-toggle .caret { margin-left: auto; color: var(--ink-3); transition: transform var(--t); }
.trash-toggle.open .caret { transform: rotate(90deg); }
.trash-list { display: none; margin-top: 6px; }
.trash-list.open { display: block; }
.trash-empty { font-size: 12.5px; color: var(--ink-3); padding: 14px 0; }
.trash-item {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 0; border-bottom: 1px solid var(--line);
}
.trash-info { flex: 1; min-width: 0; }
.trash-title { font-size: 14px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trash-meta { font-size: 11.5px; color: var(--ink-3); margin-top: 5px; }
.trash-actions { display: flex; gap: 8px; flex: none; }
.trash-actions .btn { min-height: 38px; border-color: var(--line-2); }

@media (max-width: 640px) {
  .shelf-actions { gap: 8px; }
  .section-bar .count { display: none; }
  .trash-item { flex-wrap: wrap; }
  .trash-actions { width: 100%; justify-content: flex-end; }
  .trash-actions .btn, .manage-actions .btn, .confirm-actions .btn { min-height: 46px; }
  .detail-row span:last-child { max-width: 58%; }
}
