#ep-tool-app {
  margin: 0 auto;
  width: 96%;
  max-width: 1280px;
  transition: max-width 0.4s;
  height: 85vh;
  min-height: 650px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: inherit;
  background-color: #f8fafc;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  color: #1e293b;
  position: relative;
  box-sizing: border-box;
}
#ep-tool-app.ep-tool-narrow {
  max-width: 750px;
}
#ep-tool-app *,
#ep-tool-app ::after,
#ep-tool-app ::before {
  box-sizing: inherit;
}
#ep-tool-app .ep-tool-hidden {
  display: none !important;
}
#ep-tool-app .ep-tool-intro {
  text-align: center;
  padding: 40px 20px 0;
}
#ep-tool-app .ep-tool-main-title {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 12px;
  line-height: 1.2;
}
#ep-tool-app .ep-tool-main-subtitle {
  font-size: 16px;
  color: #64748b;
  margin: 0 auto;
  max-width: 600px;
}
#ep-tool-app .ep-tool-msg-box {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #ef4444;
  color: #fff;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
#ep-tool-app .ep-tool-msg-box.ep-tool-show {
  opacity: 1;
}
#ep-tool-app .ep-tool-dropzone {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  margin: 40px;
  border: 2px dashed #cbd5e1;
  border-radius: 12px;
  background-color: #fff;
  cursor: pointer;
  transition: 0.2s;
}
#ep-tool-app .ep-tool-dropzone.ep-tool-dragover,
#ep-tool-app .ep-tool-dropzone:hover {
  border-color: #3b82f6;
  background-color: #eff6ff;
}
#ep-tool-app .ep-tool-drop-icon {
  font-size: 48px;
  color: #3b82f6;
  margin-bottom: 16px;
}
#ep-tool-app .ep-tool-drop-title {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 8px;
  color: #0f172a;
}
#ep-tool-app .ep-tool-drop-subtitle {
  font-size: 14px;
  color: #64748b;
  margin: 0;
}
#ep-tool-app .ep-tool-editor-view {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#ep-tool-app .ep-tool-toolbar {
  height: 64px;
  background-color: #fff;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 12px;
  flex-shrink: 0;
  z-index: 10;
  flex-wrap: wrap;
}
#ep-tool-app .ep-tool-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid #cbd5e1;
  background-color: #fff;
  color: #334155;
  transition: 0.2s;
  outline: 0;
  text-decoration: none;
}
#ep-tool-app .ep-tool-btn:hover {
  background-color: #f1f5f9;
}
#ep-tool-app .ep-tool-btn.ep-tool-active {
  background-color: #eff6ff;
  border-color: #bfdbfe;
  color: #1d4ed8;
}
#ep-tool-app .ep-tool-btn-primary {
  background-color: #2563eb;
  color: #fff;
  border-color: #2563eb;
  margin-left: auto;
}
#ep-tool-app .ep-tool-btn-primary:hover {
  background-color: #1d4ed8;
  border-color: #1d4ed8;
}
#ep-tool-app .ep-tool-btn-danger {
  background-color: #fee2e2;
  color: #ef4444;
  border-color: #fca5a5;
  width: 100%;
  margin-top: 20px;
}
#ep-tool-app .ep-tool-btn-danger:hover {
  background-color: #fecaca;
}
#ep-tool-app .ep-tool-btn-outline {
  background-color: transparent;
  color: #475569;
  border: 1px solid #cbd5e1;
}
#ep-tool-app .ep-tool-btn-outline:hover {
  background-color: #f1f5f9;
  color: #0f172a;
}
#ep-tool-app .ep-tool-main-area {
  flex: 1;
  display: flex;
  flex-direction: row;
  overflow: hidden;
}
#ep-tool-app .ep-tool-workspace {
  flex: 1;
  background-color: #cbd5e1;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 40px 20px;
}
#ep-tool-app .ep-tool-canvas-wrapper {
  position: relative;
  background-color: #fff;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  max-width: 100%;
}
#ep-tool-app .ep-tool-pdf-layer {
  display: block;
  pointer-events: none;
  max-width: 100%;
}
#ep-tool-app .ep-tool-fabric-layer-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}
#ep-tool-app .ep-tool-sidebar {
  width: 280px;
  background-color: #fff;
  border-left: 1px solid #e2e8f0;
  flex-shrink: 0;
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
#ep-tool-app .ep-tool-form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
#ep-tool-app .ep-tool-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  color: #64748b;
  letter-spacing: 0.5px;
}
#ep-tool-app .ep-tool-color-input {
  width: 100%;
  height: 40px;
  padding: 0;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  cursor: pointer;
}
#ep-tool-app .ep-tool-text-input {
  width: 100%;
  padding: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-family: inherit;
  font-size: 14px;
  resize: vertical;
}
#ep-tool-app .ep-tool-loading-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.95);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 50;
}
#ep-tool-app .ep-tool-spinner {
  width: 60px;
  height: 60px;
  border: 4px solid #f1f5f9;
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: 1s linear infinite ep-tool-spin;
  margin-bottom: 24px;
}
@keyframes ep-tool-spin {
  to {
    transform: rotate(360deg);
  }
}
#ep-tool-app .ep-tool-progress-track {
  width: 300px;
  height: 8px;
  background-color: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 16px;
}
#ep-tool-app .ep-tool-progress-bar {
  height: 100%;
  width: 0%;
  background-color: #3b82f6;
  transition: width 0.3s;
}
#ep-tool-app .ep-tool-loading-text {
  font-size: 16px;
  font-weight: 500;
  color: #334155;
}
#ep-tool-app .ep-tool-result-view {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: #fff;
  text-align: center;
  padding: 40px;
}
#ep-tool-app .ep-tool-success-icon {
  font-size: 64px;
  color: #10b981;
  margin-bottom: 24px;
}
#ep-tool-app .ep-tool-result-title {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 12px;
}
#ep-tool-app .ep-tool-result-desc {
  font-size: 16px;
  color: #64748b;
  margin-bottom: 32px;
}
#ep-tool-app .ep-tool-result-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}
#ep-tool-app .ep-tool-icon-svg-small {
  margin-right: 6px;
  display: inline-block;
  vertical-align: middle;
}
@media (max-width: 768px) {
  #ep-tool-app .ep-tool-main-area {
    flex-direction: column;
  }
  #ep-tool-app .ep-tool-sidebar {
    width: 100%;
    height: 200px;
    border-left: none;
    border-top: 1px solid #e2e8f0;
  }
  #ep-tool-app .ep-tool-toolbar {
    height: auto;
    padding: 12px;
  }
  #ep-tool-app .ep-tool-btn-primary {
    margin-left: 0;
    width: 100%;
    margin-top: 8px;
  }
}