/* ============================================================
   UPLOAD-MODAL.CSS — Global artwork upload modal
   ============================================================ */

#upm-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
}

#upm-overlay.active {
  display: flex;
  animation: upm-fade-in 0.18s ease;
}

@keyframes upm-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

#upm-modal {
  background: #fff;
  border-radius: 20px;
  padding: 2.25rem 2.5rem 2.5rem;
  max-width: 480px;
  width: 100%;
  position: relative;
  text-align: center;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
  animation: upm-slide-up 0.22s cubic-bezier(0.34, 1.4, 0.64, 1);
}

@keyframes upm-slide-up {
  from { transform: translateY(20px) scale(0.97); opacity: 0; }
  to   { transform: translateY(0)    scale(1);    opacity: 1; }
}

#upm-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 32px;
  height: 32px;
  border: none;
  background: #f3f4f6;
  border-radius: 50%;
  font-size: 1.2rem;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
#upm-close:hover { background: #e5e7eb; color: #111; }

#upm-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
}

#upm-head h2 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #111827;
  margin: 0.25rem 0 0;
  line-height: 1.2;
}

#upm-head p {
  font-size: 0.85rem;
  color: #9ca3af;
  margin: 0;
}

/* ---- Drop Zone ---- */
#upm-zone {
  border: 2.5px dashed #e5e7eb;
  border-radius: 14px;
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  cursor: default;
  transition: border-color 0.2s, background 0.2s;
  background: #fafafa;
}

#upm-zone.drag-over {
  border-color: #FF3B5C;
  background: rgba(255, 59, 92, 0.04);
}

.upm-zone-main {
  font-size: 0.95rem;
  font-weight: 600;
  color: #374151;
}

.upm-zone-sub {
  font-size: 0.8rem;
  color: #9ca3af;
}

.upm-browse-btn {
  display: inline-block;
  padding: 0.55rem 1.4rem;
  background: #111827;
  color: #fff;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.12s;
  margin-top: 0.25rem;
  user-select: none;
}

.upm-browse-btn:hover {
  background: #000;
  transform: translateY(-1px);
}

.upm-browse-btn:active {
  transform: translateY(0);
}

/* ---- Loading state ---- */
#upm-loading {
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2.5rem 0;
  color: #6b7280;
  font-size: 0.9rem;
}

.upm-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #f3f4f6;
  border-top-color: #FF3B5C;
  border-radius: 50%;
  animation: upm-spin 0.7s linear infinite;
}

@keyframes upm-spin {
  to { transform: rotate(360deg); }
}

/* ---- Mobile ---- */
@media (max-width: 520px) {
  #upm-modal {
    padding: 2rem 1.5rem;
    border-radius: 16px;
  }
  #upm-zone {
    padding: 2rem 1.25rem;
  }
}
