/* Pro uploader styles */
#uploader { max-width: 900px; margin: 20px auto; padding: 16px; display: grid; gap: 14px; }
.controls { display: flex; gap: 8px; flex-wrap: wrap; }
.controls button { padding: 10px 14px; border: 1px solid #ccc; border-radius: 10px; background:#fafafa; }
.controls .primary { border-color:#888; }
.hint { font-size:12px; opacity:.7; }
.dropzone {
  border: 2px dashed #bbb; border-radius: 14px; padding: 18px; text-align:center; background:#fcfcfc;
}
.dropzone.drag { border-color:#666; background:#f3f3f3; }
input[type="file"] { display:none; }

.gallery { display:grid; gap:12px; grid-template-columns: repeat(auto-fill,minmax(160px,1fr)); }
.tile {
  position:relative; border:1px solid #e3e3e3; border-radius:14px; padding:10px; background:#fff; display:grid; gap:6px;
}
.thumb { width:100%; aspect-ratio:1/1; object-fit:contain; border-radius:10px; background:#f7f7f7; }
.name { font-size:12px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.meta { font-size:11px; opacity:.75; }
.bar { height:6px; border-radius:999px; background:#eee; overflow:hidden; }
.bar > div { height:100%; width:0%; background:#888; transition:width .2s ease; }
.status { font-size:12px; min-height:16px; }
.actions { display:flex; gap:6px; }
.actions button { font-size:12px; padding:6px 8px; border:1px solid #ddd; border-radius:8px; background:#fafafa; }
.tile.success .status { color:#0a7a28; }
.tile.error   .status { color:#b00020; }
.hidden { display: none; }

.toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: 16px; background:#111; color:#fff; padding:10px 14px;
  border-radius: 10px; font-size: 13px; z-index: 9999; opacity: .95;
}

.magic {
  border: 1px solid #e6e6e6; border-radius: 12px; padding: 10px; background:#fff; display:grid; gap:8px;
}
.magic h4 { margin: 0; font-size: 14px; }
.magic .kv { font-size: 13px; line-height: 1.35; }
.magic .badge { display:inline-block; font-size:11px; padding:3px 8px; border-radius:999px; background:#efe9ff; }
.magic .btn-row { display:flex; gap:8px; }
.magic button.magic-act { font-size:12px; padding:6px 10px; border:1px solid #ddd; border-radius:8px; background:#fafafa; }
.magic .price { font-weight:600; }
.magic .muted { opacity:.75; font-size:12px; }
.tile .magic { margin-top: 6px; }