.capability-actions {
  display: none;
}
.capability-preview {
  display: block;
  max-width: 100%;
  max-height: 320px;
  margin: 16px auto;
  object-fit: contain;
  border: 1px solid var(--editor-border, #dce0eb);
  border-radius: 12px;
  background: repeating-conic-gradient(#f4f5f8 0% 25%, white 0% 50%) 0 0/16px
    16px;
}
.capability-preview[hidden] {
  display: none;
}
.rectify-stage {
  position: relative;
  width: fit-content;
  max-width: 100%;
  margin: 12px auto;
}
.rectify-stage canvas {
  display: block;
  max-width: 100%;
  height: auto;
}
.rectify-handle {
  position: absolute;
  width: 24px;
  height: 24px;
  min-height: 0;
  padding: 0;
  border-radius: 50%;
  border: 3px solid white;
  background: #6354cf;
  transform: translate(-50%, -50%);
  touch-action: none;
  box-shadow: 0 0 0 1px #6354cf;
}
.rectify-handle:focus-visible {
  outline: 3px solid #ffbd43;
  outline-offset: 3px;
}
.animation-frames {
  max-height: 360px;
  overflow: auto;
  border: 1px solid var(--ws-border, #3b4450);
  border-radius: 12px;
}
.animation-frame {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px;
  border-bottom: 1px solid var(--ws-border, #3b4450);
}
.animation-frame.selected {
  background: var(--ws-accent-soft, #2f4030);
}
.animation-frame button:first-child {
  flex: 1 1 180px;
  text-align: left;
  min-width: 96px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.animation-frame button {
  flex-shrink: 0;
  white-space: nowrap;
}
.animation-frame input {
  flex: 0 0 90px;
  min-width: 0;
  width: 90px;
}
.industry-assets-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.industry-assets-grid button {
  display: grid;
  place-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--ws-border, #3b4450);
  border-radius: 12px;
}
.industry-assets-grid img {
  width: 56px;
  height: 56px;
}
.live-cursors {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 6;
}
.live-cursor {
  position: absolute;
  white-space: nowrap;
  padding: 3px 6px 3px 18px;
  background: #6354cf;
  color: white;
  border-radius: 4px;
  font-size: 11px;
}
.live-cursor:before {
  content: "↖";
  position: absolute;
  left: 2px;
  top: -8px;
  font-size: 22px;
  color: #6354cf;
  text-shadow: 0 0 2px white;
}
@media (max-width: 650px) {
  .animation-frame {
    flex-wrap: wrap;
  }
  .animation-frame button:first-child {
    flex-basis: 100%;
  }
  .industry-assets-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .rectify-handle {
    width: 44px;
    height: 44px;
  }
}
.template-card > button:first-child {
  display: grid;
  width: 100%;
  gap: 10px;
  padding: 10px;
  text-align: left;
  border: 1px solid var(--ws-border, #3b4450);
  border-radius: 12px;
  background: var(--ws-panel, #20262d);
  color: var(--ws-text, #edf1f5);
}
.template-card > button:first-child img {
  width: 100%;
  height: 160px;
  object-fit: contain;
  background: #f5f5f8;
  border-radius: 8px;
}
.template-card > button:first-child span {
  font-weight: 600;
  line-height: 1.5;
}
.template-card > button:first-child:hover {
  border-color: var(--ws-accent, #c5f582);
  background: var(--ws-raised, #242f2b);
}
.template-card > button:first-child:focus-visible {
  outline: 3px solid #c5f582;
  outline-offset: 2px;
}
