.content-workbench-editor {
  display: grid;
  gap: var(--ms-space-3);
}

.content-workbench-editor-panel {
  min-width: 0;
}

.content-workbench-editor-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ms-space-2);
}

.content-workbench-editor-header__body {
  min-width: 0;
}

.content-workbench-editor-header__label {
  margin: 0;
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-label);
  font-weight: 500;
  line-height: var(--ms-leading-label);
}

.content-workbench-editor-header__meta {
  overflow: hidden;
  margin: 2px 0 0;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-caption);
  line-height: var(--ms-leading-caption);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-workbench-editor-header__actions,
.content-workbench-editor-actions {
  display: flex;
  flex-shrink: 0;
  flex-wrap: wrap;
  gap: 6px;
}

.content-workbench-editor-field-grid {
  display: grid;
  gap: var(--ms-space-2);
}

.content-workbench-editor-field-grid--keyframe-meta {
  margin-top: var(--ms-space-3);
}

.content-workbench-editor-field-grid + .content-workbench-editor-field-grid {
  margin-top: var(--ms-space-2);
}

.content-workbench-editor-field {
  display: grid;
  gap: 6px;
}

.content-workbench-editor-field__label {
  font-size: var(--ms-text-label);
  line-height: var(--ms-leading-label);
}

.content-workbench-editor-select-trigger {
  height: 36px;
}

.content-workbench-editor-generation {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--ms-space-2);
}

.content-workbench-editor-field-grid + .content-workbench-editor-generation {
  margin-top: var(--ms-space-3);
}

.content-workbench-editor-generation .content-workbench-editor-field {
  min-width: 220px;
  flex: 1;
}

.content-workbench-editor-generation__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.content-workbench-keyframe-list-section {
  min-width: 0;
}

.content-workbench-keyframe-list-section__body {
  max-height: 320px;
  overflow: auto;
  padding: var(--ms-space-2);
}

.content-workbench-keyframe-list {
  min-width: 0;
}

.content-workbench-keyframe-list-item {
  display: grid;
  width: 100%;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: flex-start;
  gap: var(--ms-space-2);
  text-align: left;
}

.content-workbench-keyframe-thumbnail {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.content-workbench-keyframe-thumbnail__media,
.content-workbench-keyframe-thumbnail__fallback {
  display: flex;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
}

.content-workbench-keyframe-thumbnail__media > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.content-workbench-keyframe-thumbnail__fallback {
  font-size: var(--ms-text-tiny);
  line-height: var(--ms-leading-tiny);
}

.content-workbench-keyframe-list-item__copy {
  min-width: 0;
}

.content-workbench-keyframe-list-item__title,
.content-workbench-keyframe-list-item__detail {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-workbench-keyframe-list-item__title {
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-label);
  font-weight: 500;
  line-height: var(--ms-leading-label);
}

.content-workbench-keyframe-list-item__detail {
  margin-top: 2px;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-caption);
  line-height: var(--ms-leading-caption);
}

.content-workbench-keyframe-list-item__status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--ms-space-1);
}

.content-workbench-keyframe-detail {
  min-width: 0;
}

.content-workbench-keyframe-action-button {
  gap: 6px;
}

.content-workbench-keyframe-textarea {
  min-height: 96px;
}

.content-workbench-quick-create-card {
  min-width: 0;
}

.content-workbench-quick-create-card__body {
  display: grid;
  gap: var(--ms-space-4);
  padding: var(--ms-space-4);
}

.content-workbench-quick-create-field {
  display: grid;
  gap: 6px;
}

.content-workbench-quick-create-field__label {
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-label);
  line-height: var(--ms-leading-label);
}

.content-workbench-quick-create-field__detail {
  margin: 0;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-caption);
  line-height: 1.45;
}

.content-workbench-quick-create-select-trigger {
  height: 40px;
  background: var(--ms-color-background);
}

.content-workbench-quick-create-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--ms-space-2);
}

.content-workbench-quick-create-action-button {
  gap: var(--ms-space-2);
}

@media (min-width: 640px) {
  .content-workbench-editor-field-grid--keyframe-meta {
    grid-template-columns: 140px minmax(0, 1fr) 96px;
  }

  .content-workbench-editor-field-grid--unit-title {
    grid-template-columns: minmax(0, 1fr) 112px;
  }
}

@media (min-width: 1024px) {
  .content-workbench-editor--split {
    grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.2fr);
  }

  .content-workbench-editor-field-grid--two:not(.content-workbench-editor-field-grid--compact) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.content-workbench-unit-edit {
  min-height: 180px;
  padding-block: var(--ms-space-3);
}

.content-workbench-unit-edit-empty-state {
  min-width: 0;
}

.content-workbench-unit-edit-grid {
  display: grid;
  gap: var(--ms-space-3);
}

.content-workbench-unit-edit-section {
  border-top: 1px solid var(--ms-color-border);
  padding-top: var(--ms-space-3);
}

.content-workbench-unit-edit-section:first-child {
  border-top: 0;
  padding-top: 0;
}

.content-workbench-unit-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ms-space-2);
}

.content-workbench-unit-summary__body {
  min-width: 0;
}

.content-workbench-unit-summary__badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ms-space-2);
}

.content-workbench-unit-summary__title {
  overflow: hidden;
  margin: var(--ms-space-2) 0 0;
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-body);
  font-weight: 600;
  line-height: var(--ms-leading-body);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-workbench-unit-summary__meta {
  display: -webkit-box;
  overflow: hidden;
  margin: var(--ms-space-1) 0 0;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-label);
  line-height: 1.45;
}

.content-workbench-unit-summary__actions,
.content-workbench-unit-edit-action-row,
.content-workbench-unit-edit-blockers {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.content-workbench-unit-summary__actions {
  flex-shrink: 0;
  align-items: center;
}

.content-workbench-unit-edit-action-row {
  justify-content: center;
}

.content-workbench-unit-edit-action-button {
  gap: 6px;
}

.content-workbench-unit-edit-textarea {
  min-height: 140px;
}

.content-workbench-unit-edit-textarea--compact {
  min-height: 180px;
}

.content-workbench-unit-edit-section > .content-workbench-editor-field-grid,
.content-workbench-unit-edit-section > .content-workbench-unit-edit-blockers {
  margin-top: var(--ms-space-3);
}

.content-workbench-generation-input-section {
  min-width: 0;
}

.content-workbench-generation-input-section__body {
  display: grid;
  gap: var(--ms-space-2);
}

.content-workbench-input-card-grid {
  display: grid;
  gap: var(--ms-space-2);
}

.content-workbench-input-card {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: flex-start;
  gap: var(--ms-space-2);
  padding: var(--ms-space-2) 10px;
  transition: background-color var(--ms-duration-fast) var(--ms-easing-standard), border-color var(--ms-duration-fast) var(--ms-easing-standard);
}

.content-workbench-input-card[role="button"] {
  cursor: pointer;
}

.content-workbench-input-card[role="button"]:hover {
  border-color: color-mix(in srgb, var(--ms-color-primary) 50%, transparent);
  background: color-mix(in srgb, var(--ms-color-muted) 40%, transparent);
}

.content-workbench-input-card[role="button"]:focus-visible {
  outline: 2px solid var(--ms-color-primary);
  outline-offset: 2px;
}

.content-workbench-input-card__icon {
  display: inline-flex;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  border-radius: var(--ms-radius-md);
  background: var(--ms-color-muted);
  color: var(--ms-color-muted-foreground);
}

.content-workbench-input-card__icon[data-tone="success"] {
  background: color-mix(in srgb, var(--ms-color-success) 12%, transparent);
  color: var(--ms-color-success);
}

.content-workbench-input-card__icon[data-tone="warning"] {
  background: color-mix(in srgb, var(--ms-color-warning) 12%, transparent);
  color: var(--ms-color-warning);
}

.content-workbench-input-card__body {
  min-width: 0;
}

.content-workbench-input-card__title-row {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.content-workbench-input-card__title {
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-label);
  font-weight: 500;
  line-height: var(--ms-leading-label);
}

.content-workbench-input-card__badge {
  font-size: var(--ms-text-tiny);
  line-height: var(--ms-leading-tiny);
}

.content-workbench-input-card__detail {
  display: block;
  margin-top: var(--ms-space-1);
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-caption);
  line-height: 1.35;
}

.content-workbench-input-card__aside {
  display: flex;
  max-width: 128px;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--ms-space-2);
}

.content-workbench-input-action-group {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ms-space-2);
}

.content-workbench-input-action-button {
  gap: 6px;
}

.content-workbench-input-drawer {
  padding: var(--ms-space-3);
}

.content-workbench-input-drawer--wide {
  grid-column: span 2;
}

.content-workbench-input-drawer-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--ms-space-3);
}

.content-workbench-input-drawer-header__title {
  margin: 0;
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-body);
  font-weight: 600;
  line-height: var(--ms-leading-body);
}

.content-workbench-input-drawer-header__description {
  margin: var(--ms-space-1) 0 0;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-label);
  line-height: 1.45;
}

.content-workbench-input-drawer-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.content-workbench-input-drawer-panel {
  margin-top: var(--ms-space-3);
}

.content-workbench-generation-readiness {
  display: grid;
  gap: var(--ms-space-3);
}

.content-workbench-generation-readiness__title {
  margin: 0;
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-label);
  font-weight: 500;
  line-height: var(--ms-leading-label);
}

.content-workbench-generation-readiness__summary {
  margin: var(--ms-space-1) 0 0;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-label);
  line-height: 1.45;
}

.content-workbench-generation-readiness__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: var(--ms-space-2);
}

.content-workbench-generation-readiness__action {
  align-self: start;
}

.content-workbench-planning-editor {
  display: grid;
  gap: var(--ms-space-3);
}

.content-workbench-planning-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ms-space-2);
}

.content-workbench-planning-header__title {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--ms-color-foreground);
  font-size: var(--ms-text-label);
  font-weight: 500;
  line-height: var(--ms-leading-label);
}

.content-workbench-planning-header__icon {
  display: inline-flex;
  flex-shrink: 0;
  color: var(--ms-color-muted-foreground);
}

.content-workbench-planning-header__description {
  margin: var(--ms-space-1) 0 0;
  color: var(--ms-color-muted-foreground);
  font-size: var(--ms-text-label);
  line-height: 1.45;
}

.content-workbench-planning-header__actions {
  display: flex;
  flex-shrink: 0;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.content-workbench-planning-action-button {
  gap: 6px;
}

.content-workbench-planning-field-grid {
  display: grid;
  gap: var(--ms-space-2);
}

.content-workbench-planning-field-grid + .content-workbench-planning-field-grid {
  margin-top: var(--ms-space-2);
}

.content-workbench-planning-textarea {
  width: 100%;
}

.content-workbench-planning-textarea--sm {
  min-height: 72px;
}

.content-workbench-planning-textarea--md {
  min-height: 76px;
}

.content-workbench-planning-textarea--lg {
  min-height: 88px;
}

@media (min-width: 1024px) {
  .content-workbench-generation-readiness {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

@media (min-width: 640px) {
  .content-workbench-planning-field-grid--two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1280px) {
  .content-workbench-unit-edit-grid--split {
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  }

  .content-workbench-unit-edit-grid--split .content-workbench-unit-edit-section--wide {
    grid-column: span 2;
  }
}
