.canvas-wrapper {
  position: relative;
  min-width: 100%;
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.drop-overlay {
  position: absolute;
  inset: 16px;
  background: rgba(var(--gradient-mint-rgb), 0.08);
  border: 2px dashed rgba(var(--primary-rgb), 0.35);
  border-radius: 16px;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
  backdrop-filter: blur(8px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.drop-overlay--active {
  display: flex;
  border-color: rgba(var(--primary-rgb), 0.6);
  background: rgba(var(--gradient-mint-rgb), 0.14);
}
.drop-overlay .drop-message {
  text-align: center;
  color: var(--ink);
  padding: 44px 36px;
  background: var(--surface-card);
  border-radius: 16px;
  box-shadow: 0 16px 48px -8px rgba(var(--ink-rgb), 0.12), 0 0 0 1px rgba(var(--primary-rgb), 0.08);
  border: 1px solid var(--hairline-soft);
  animation: fadeInScale 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.drop-overlay .drop-message svg {
  margin-bottom: 16px;
  color: var(--primary);
  opacity: 0.9;
}
.drop-overlay .drop-message p {
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
}
.drop-overlay .drop-message .drop-hint {
  font-size: 13px;
  color: var(--muted);
  margin-top: 6px;
}

.editor-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  animation: fadeInScale 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}
.editor-preview .editor-preview-image {
  max-width: 100%;
  max-height: calc(100vh - 140px);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(var(--ink-rgb), 0.04), 0 12px 40px -4px rgba(var(--ink-rgb), 0.1);
  border: 1px solid var(--hairline-soft);
  background: var(--surface-card);
  transition: box-shadow 0.3s ease, opacity 0.4s ease, filter 0.4s ease;
}
.editor-preview .editor-preview-image:hover {
  box-shadow: 0 1px 3px rgba(var(--ink-rgb), 0.04), 0 20px 56px -8px rgba(var(--ink-rgb), 0.14);
}
.editor-preview .editor-preview-image img {
  max-width: 100%;
  max-height: calc(100vh - 140px);
  display: block;
  object-fit: contain;
}
.editor-preview .editor-preview-image--processing {
  opacity: 0.35;
  filter: blur(2px) saturate(0.6);
}

.editor-processing {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  z-index: 10;
  animation: fadeInScale 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.editor-processing .processing-ring {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 3px solid var(--hairline-soft);
  border-top-color: var(--primary);
  animation: spin 0.9s linear infinite;
  position: relative;
}
.editor-processing .processing-ring::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top-color: rgba(var(--primary-rgb), 0.3);
  animation: spin 1.4s linear infinite reverse;
}
.editor-processing .processing-text {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.3px;
}
.editor-processing .processing-text .processing-label {
  background: linear-gradient(135deg, var(--primary), var(--gradient-mint));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.editor-processing .processing-text .processing-dots {
  display: inline-flex;
  gap: 2px;
}
.editor-processing .processing-text .processing-dots span {
  animation: bounceDots 1.4s ease-in-out infinite;
  color: var(--primary);
  font-weight: 700;
}
.editor-processing .processing-text .processing-dots span:nth-child(2) {
  animation-delay: 0.2s;
}
.editor-processing .processing-text .processing-dots span:nth-child(3) {
  animation-delay: 0.4s;
}
.editor-processing .processing-hint {
  font-size: 12px;
  color: var(--muted-soft);
  letter-spacing: 0.5px;
  padding: 6px 14px;
  background: var(--surface-card);
  border: 1px solid var(--hairline-soft);
  border-radius: 9999px;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes bounceDots {
  0%, 60%, 100% {
    opacity: 0.3;
    transform: translateY(0);
  }
  30% {
    opacity: 1;
    transform: translateY(-4px);
  }
}
.sidebar-section {
  padding: 18px;
  border: 1px solid var(--hairline-soft);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--surface-card);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.sidebar-section:hover {
  border-color: var(--hairline);
  box-shadow: 0 2px 12px rgba(var(--ink-rgb), 0.04);
}

.sidebar-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  color: var(--muted-soft);
  text-transform: uppercase;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar-title::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 2px;
  background: linear-gradient(90deg, var(--gradient-mint), var(--gradient-peach));
  border-radius: 1px;
}

.setting-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.setting-label {
  display: flex;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted-soft);
  text-transform: uppercase;
  letter-spacing: 0.96px;
  align-items: center;
}

.preset-scenes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.preset-scene-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  background: linear-gradient(135deg, var(--canvas-soft) 0%, rgba(var(--surface-card-rgb), 0.6) 100%);
  border: 1px solid var(--hairline-soft);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  position: relative;
  overflow: hidden;
  min-width: 0;
}
.preset-scene-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--gradient-mint), var(--gradient-peach));
  opacity: 0;
  transition: opacity 0.3s ease;
}
.preset-scene-btn:hover {
  background: var(--surface-strong);
  border-color: var(--hairline-strong);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px -4px rgba(var(--ink-rgb), 0.1), 0 0 0 1px rgba(var(--primary-rgb), 0.06);
}
.preset-scene-btn:hover::before {
  opacity: 1;
}
.preset-scene-btn:hover .preset-scene-icon {
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
  border-color: rgba(var(--primary-rgb), 0.25);
  transform: scale(1.08);
}
.preset-scene-btn:active {
  transform: translateY(0) scale(0.97);
  box-shadow: none;
}
.preset-scene-btn .preset-scene-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--surface-card);
  border: 1px solid var(--hairline-soft);
  color: var(--muted);
  flex-shrink: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.preset-scene-btn .preset-scene-icon svg {
  width: 18px;
  height: 18px;
}
.preset-scene-btn span:last-child {
  line-height: 1.3;
  min-width: 0;
  overflow-wrap: break-word;
  word-break: break-word;
}

.setting-textarea {
  width: 100%;
  padding: 14px 16px;
  background: var(--surface-strong);
  border: 1px solid var(--hairline-soft);
  border-radius: 12px;
  color: var(--ink);
  font-size: 14px;
  font-family: inherit;
  line-height: 1.7;
  resize: vertical;
  min-height: 90px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: inset 0 1px 3px rgba(var(--ink-rgb), 0.04);
}
.setting-textarea::placeholder {
  color: var(--muted-soft);
  font-style: italic;
}
.setting-textarea:hover {
  border-color: var(--hairline-strong);
  background: var(--surface-card);
}
.setting-textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--surface-card);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1), inset 0 1px 3px rgba(var(--ink-rgb), 0.02);
}

.setting-hint {
  display: block;
  font-size: 11px;
  color: var(--muted-soft);
  margin-top: 2px;
  line-height: 1.5;
  padding-left: 2px;
}

.setting-select-wrapper {
  position: relative;
  width: 100%;
}
.setting-select-wrapper select {
  width: 100%;
  padding: 11px 36px 11px 14px;
  background: var(--surface-strong);
  border: 1px solid var(--hairline-soft);
  border-radius: 12px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  font-family: inherit;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: inset 0 1px 2px rgba(var(--ink-rgb), 0.03);
}
.setting-select-wrapper select:hover {
  border-color: var(--hairline-strong);
  background: var(--surface-card);
}
.setting-select-wrapper select:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--surface-card);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}
.setting-select-wrapper select option {
  background: var(--surface-card);
  color: var(--ink);
  padding: 8px;
}
.setting-select-wrapper::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 4px solid var(--muted);
  pointer-events: none;
  z-index: 1;
  opacity: 0.7;
}

.result-value {
  font-weight: 600;
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 9999px;
  background: var(--surface-strong);
}
.result-value--processing {
  color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
  animation: pulse 1.5s ease-in-out infinite;
}
.result-value--success {
  color: var(--semantic-success);
  background: rgba(var(--semantic-success-rgb), 0.1);
}
.result-value--error {
  color: var(--semantic-error);
  background: rgba(var(--semantic-error-rgb), 0.1);
}

.result-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding: 24px;
  background: var(--canvas-soft);
}
.result-compare .result-compare-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--surface-card);
  border-radius: 12px;
  border: 1px solid var(--hairline-soft);
  transition: border-color 0.2s ease;
}
.result-compare .result-compare-item:hover {
  border-color: var(--hairline);
}
.result-compare .result-compare-item .result-compare-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted-soft);
  padding: 5px 14px;
  background: var(--canvas-soft);
  border-radius: 9999px;
  border: 1px solid var(--hairline-soft);
}
.result-compare .result-compare-item img {
  max-width: 100%;
  max-height: 50vh;
  border-radius: 8px;
  border: 1px solid var(--hairline-soft);
  box-shadow: 0 4px 16px rgba(var(--ink-rgb), 0.06);
  background: var(--surface-card);
}

.modal-overlay .modal {
  background: var(--surface-card);
  border: 1px solid var(--hairline);
  border-radius: 24px;
  box-shadow: 0 32px 64px -16px rgba(var(--ink-rgb), 0.15), 0 0 0 1px rgba(var(--ink-rgb), 0.04);
  animation: fadeInScale 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}
.modal-overlay .modal .modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--hairline-soft);
  background: linear-gradient(135deg, var(--surface-card) 0%, var(--canvas-soft) 100%);
}
.modal-overlay .modal .modal-header .modal-title {
  font-family: "Waldenburg", "Times New Roman", serif;
  font-size: 18px;
  font-weight: 300;
  color: var(--ink);
  letter-spacing: -0.3px;
}
.modal-overlay .modal .modal-header .modal-close {
  width: 34px;
  height: 34px;
  border: none;
  background: var(--surface-strong);
  border-radius: 8px;
  color: var(--muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  line-height: 1;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.modal-overlay .modal .modal-header .modal-close:hover {
  background: var(--semantic-error);
  color: white;
  transform: rotate(90deg);
}
.modal-overlay .modal .modal-body {
  padding: 0;
}
.modal-overlay .modal .modal-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 24px;
  border-top: 1px solid var(--hairline-soft);
  gap: 12px;
  background: var(--canvas-soft);
}

.empty-state svg {
  opacity: 0.35;
  transition: opacity 0.3s ease;
}
.empty-state:hover svg {
  opacity: 0.5;
}
.empty-state p {
  font-size: 20px;
  font-weight: 300;
  letter-spacing: -0.5px;
  color: var(--ink);
  margin-bottom: 6px;
}
.empty-state .empty-hint-sub {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 28px;
  line-height: 1.5;
}
.empty-state .empty-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.footer .footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 32px;
  padding: 0 20px;
}
.footer .footer-status {
  display: flex;
  align-items: center;
  gap: 20px;
}
.footer .footer-status-item {
  font-size: 12px;
  font-weight: 500;
  color: rgba(var(--on-primary-rgb), 0.7);
}
.footer .footer-text {
  font-size: 12px;
  font-weight: 400;
  color: rgba(var(--on-primary-rgb), 0.45);
}

@media (max-width: 768px) {
  .preset-scenes {
    grid-template-columns: 1fr;
  }
  .result-compare {
    grid-template-columns: 1fr;
    padding: 16px;
    gap: 16px;
  }
  .result-compare .result-compare-item {
    padding: 12px;
  }
  .result-compare .result-compare-item img {
    max-height: 32vh;
  }
  .editor-preview .editor-preview-image {
    max-height: calc(100vh - 200px);
  }
  .editor-preview .editor-preview-image img {
    max-height: calc(100vh - 200px);
  }
  .canvas-wrapper {
    padding: 16px;
  }
  .sidebar-section {
    padding: 14px;
  }
}

/*# sourceMappingURL=magic-editor.css.map */
