/* Asimov Form Styles */

.asimov-form .render-row-error {
  color: var(--color-red);
  font-size: 0.7rem;
}

.asimov-form-problems .form-problems strong,
.asimov-form .problem.error .label-cell {
  color: var(--color-red);
}

.asimov-form {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
}

.asimov-form .formative-section {
  display: flex;
  flex-direction: column;
  background: var(--background-11);
  border-radius: 0.5rem;
  width: 100%;
  height: fit-content;
  min-height: 0;
  min-width: 0;
  padding: 0.5rem;
  margin: 0 0 0.5rem 0;
}

@media not screen and (max-width:1100px) {
  .asimov-form .formative-section.half-width {
    width: calc(50% - 0.5rem);
    margin: 0 0.5rem 0.5rem 0;
  }
}

.asimov-form .formative-section-body {
  flex: 1;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  min-height: 0;
  min-width: 0;
  padding: 0;
  margin: 0;
  overflow-x: auto;
}

.asimov-form .formative-section:has(.formative-section-expander:not(.expanded)) .formative-section-body {
  display: none;
}

.asimov-form .formative-section-expander {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem;
}

.asimov-form .formative-section-expander.expanded {
  margin-bottom: 0.5rem;
}

.asimov-form .formative-section-expander .title {
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 400;
  line-height: 1.5rem;
  margin: 0.5rem;
  padding-left: 1rem;
}

.asimov-form .formative-section-expander:not(.expanded) .collapse {
  display: none;
}

.asimov-form .formative-section-expander .collapse,
.asimov-form .formative-section-expander .expand {
  margin-left: auto;
}

.asimov-form .formative-section-expander.expanded .expand {
  display: none;
}

.asimov-form .formative-section .formative-row {
  width: calc(100% - 0.5rem);
  height: fit-content;
}

@media not screen and (max-width:1100px) {
  .asimov-form .formative-section.dual-column:not(.half-width) .formative-row:not(.heading-row) {
    width: calc(50% - 0.5rem);
  }
}

.asimov-form .formative-row:not(.heading-row) {
  padding: 0.25rem 0.5rem;
  margin: 0.25rem;
}

.asimov-form .formative-row.heading-row {
  margin: 0.25rem;
}

.asimov-form .heading-row h3 {
  color: var(--primary);
  margin: 0.25rem 0 0.25rem 1rem;
  font-size: 0.9rem;
  font-weight: 400;
}

.asimov-form .formative-row.autosave-row,
.asimov-form .formative-row:not(.shown-checked) {
  display: none;
}

.asimov-form .label-cell {
  color: var(--color-4);
  font-size: 0.6rem;
  font-weight: 400;
  margin-bottom: 0.25rem;
}

.asimov-form .label-shell {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.25rem;
  color: #00BBFF;
}

.asimov-form .field-info {
  display: inline-flex;
  align-items: baseline;
  gap: 0.25rem;
}

.asimov-form .field-info-toggle {
  width: 0.9rem;
  height: 0.9rem;
  padding: 0;
  margin: 0;
  border: none;
  background: transparent;
  color: var(--color-2);
  font-size: 0.55rem;
  line-height: 0.9rem;
}

.asimov-form .field-info-toggle:hover {
  color: var(--primary);
}

.asimov-form .field-info .hide-icon,
.asimov-form .field-info.shown .show-icon,
.asimov-form .field-info-text {
  display: none;
}

.asimov-form .field-info.shown .hide-icon {
  display: inline;
}

.asimov-form .field-info.shown .field-info-text {
  display: inline-block;
}

.asimov-form .field-info-text {
  padding: 0.2rem 0.35rem;
  border: 1px solid color-mix(in srgb, var(--color-2) 35%, transparent);
  border-radius: 0.2rem;
  color: var(--color-1);
  font-size: 0.6rem;
  line-height: 0.85rem;
}

.asimov-form .field-info-label {
  margin-right: 0.25rem;
  color: var(--color-2);
  font-weight: 600;
  text-transform: uppercase;
}

.asimov-form .textarea-row textarea:not(:focus),
.asimov-form .select-row select:not(:focus),
.asimov-form .url-row input:not(:focus),
.asimov-form .date-row input:not(:focus),
.asimov-form .datetime-select-row input:not(:focus),
.asimov-form .number-row input:not(:focus),
.asimov-form .text-row input:not(:focus) {
  border-color: var(--background-1);
}

.asimov-form .secret {
    -webkit-text-security: disc;
}

.asimov-form .textarea-row textarea,
.asimov-form .select-row select,
.asimov-form .url-row input,
.asimov-form .date-row input,
.asimov-form .datetime-select-row input,
.asimov-form .number-row input,
.asimov-form .table-row input:not([type=checkbox],[type=radio]),
.asimov-form .table-row textarea,
.asimov-form .table-row select,
.asimov-form .text-row input {
  background-color: var(--background-12);
}

.asimov-form .markdown-wysiwyg-row .markdown-wysiwyg.unknown-textarea .markdown-content,
.asimov-form .markdown-wysiwyg-row .markdown-wysiwyg.unknown-textarea .markdown-raw,
.asimov-form .textarea-row textarea.unknown-textarea {
  background-color: color-mix(in srgb, var(--background-7) 82%, var(--color-red));
  color: var(--color-1);
}

.asimov-form .markdown-wysiwyg-row .markdown-wysiwyg.na-textarea .markdown-content,
.asimov-form .markdown-wysiwyg-row .markdown-wysiwyg.na-textarea .markdown-raw,
.asimov-form .textarea-row textarea.na-textarea {
  background-color: color-mix(in srgb, var(--background-7) 60%, var(--color-2));
  color: var(--color-1);
}

.asimov-form .formative-row .input-shell > [type=date]:focus,
.asimov-form .formative-row .input-shell > select:focus {
  border-color: var(--form-element-active-border-color);
}

.asimov-form .formative-row .input-shell > [type=date],
.asimov-form .formative-row .input-shell > select {
  max-width: unset;
}

.asimov-form .formative-row .input-shell > .note {
  color: var(--color-2);
  font-size: 0.6rem;
  font-style: italic;
}

.asimov-form .table-row {
  overflow-x: auto;
}

.asimov-form .dynamic-table-row .row-popup,
.asimov-form .table-row .row-popup {
  font-size: 1rem;
  line-height: 1.5rem;
  text-align: center;
}

.asimov-form .th {
  padding: 0rem 0.5rem;
  margin: 0;
  border-bottom: none;
  font-size: 0.6rem;
}

.asimov-form .td {
  padding: 0;
  margin: 0;
  border-bottom: none;
  font-size: 0.6rem;
}

.asimov-form input:not([type=checkbox],[type=radio]),
.asimov-form textarea,
.asimov-form select {
  font-size: 0.7rem;
  font-weight: 400;
  color: var(--color-1);
  width: 100%;
  margin: 0;
  padding: 0.75rem 0.75rem 0.75rem 1rem;
}

.asimov-form textarea {
  resize: vertical;
  height: 3rem;
}

.asimov-form select {
  width: 100%;
  margin: 0;
}

.asimov-form article select,
.asimov-form article input:not([type=checkbox],[type=radio]),
.asimov-form article textarea {
  width: unset;
  margin-bottom: 0.25rem;
  margin-right: 0.25rem;
}

.asimov-form .trend svg {
  height: 100%;
  width: 100%;
  max-height: 15rem;
}

.asimov-form .link-row,
.asimov-form .link-post-row {
  font-size: 0.7rem;
}

.asimov-form .info-row .td {
  border: 1px solid var(--border-color);
  border-radius: 0.25rem;
  font-size: 0.5rem;
  padding: 0.25rem;
  color: var(--color-1);
}

.asimov-form .gauge {
  position: relative;
  width: 5rem;
}

.asimov-form .gauge .gauge-value {
  display: block;
  position: absolute;
  top: 2rem;
  left: 0;
  width: 100%;
  text-align: center;
  font-family: var(--font-family-fixed);
  font-size: 0.9rem;
}

.asimov-form .carbon-form {
  position: relative;
}

.asimov-form .carbon-form.popout {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 100vw;
  background: var(--color-bg2);
  padding: 1rem;
  border: 0.1rem solid var(--color-border2);
  z-index: 10;
  overflow: auto;
}

.asimov-form .carbon-form .pop-button {
  position: absolute;
  top: -0.8rem;
  right: 0;
}

.asimov-form .carbon-form.popout .pop-button {
  top: 0.5rem;
  right: 1rem;
}

.asimov-form .carbon-form table input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]),
.asimov-form .carbon-form table select {
  font-size: 0.8rem;
  padding: 0.25rem;
  height: 1.8rem;
  margin-bottom: 0.25rem;
}

.asimov-form .carbon-form table {
  border-collapse: collapse;
}

.asimov-form .carbon-form table th {
  /* width: 7.5rem; */
}

.asimov-form .carbon-form table td {
  padding: 0;
}

.asimov-form .attachments-form {
  font-size: 0.6rem;
  display: flex;
  flex-direction: column;
  background: var(--background-12);
  border: 1px solid var(--background-1);
  border-radius: var(--border-radius);
  padding: 0.5rem;
}

.asimov-form .attachments-form .header  {
  color: var(--color-2);
  margin: 0 0.5rem;
}

.asimov-form .attachments-form .body {
  position: relative;
  display: flex;
  /* background: var(--background-color-7); */
  border-radius: 0.25rem;
}

.asimov-form .attachments-form .body .attachment-list {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 2rem;
  padding: 0;
}

.asimov-form .attachments-form .body:has(.file-input) .attachment-list {
  margin-right: 4rem;
}

.asimov-form .attachments-form .attachment-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  /* background: var(--background-12); */
  /* border-radius: 0.25rem; */
  padding: 0.25rem 0.5rem;
  margin: 0.1rem;
}

.asimov-form .attachments-form .attachment-item .file-row {
  flex: 1 1 100%;
  display: flex;
  align-items: center;
  min-width: 0;
}

.asimov-form .attachments-form .attachment-item .file-name {
  flex: 0 0 auto;
  font-size: 0.5rem;
  line-height: 1rem;
  color: var(--color-1);
  margin: 0 0.35rem 0 0;
  padding: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.asimov-form .attachments-form .attachment-item .file-btns {
  display: flex;
  flex: 0 0 auto;
  width: auto;
  align-items: center;
  gap: 0.15rem;
  margin: 0 0.5rem 0 0;
  padding: 0;
  order: -1;
}

.asimov-form .attachments-form .attachment-item .file-btns .icon-slot {
  flex: 0 0 1.25rem;
  width: 1.25rem;
  height: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.asimov-form .attachments-form .attachment-item .icon-button {
  height: 1.25rem;
  width: 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.asimov-form .attachments-form .attachment-item .icon-button svg {
  height: 0.8rem;
  width: 0.8rem;
}

.asimov-form .attachments-form .attachment-item .file-notes {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  padding: 0.1rem 0.3rem;
  font-size: 0.5rem;
  line-height: 1rem;
  background: transparent;
  color: var(--color-1);
  border: 1px solid var(--border-color);
  border-radius: 0.2rem;
}

.asimov-form .attachments-form .file-input {
  position: absolute;
  top: 50%;
  right: 0.25rem;
  transform: translateY(-50%);
}

.asimov-form .attachments-form .recording-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 0.5rem;
}

.asimov-form .attachments-form .recording-head .header {
  margin: 0;
}

.asimov-form .attachments-form .recording-ui {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.asimov-form .attachments-form .record-button {
  color: var(--color-2);
}

.asimov-form .attachments-form .recording-controls[hidden] {
  display: none !important;
}

.asimov-form .attachments-form .recording-controls {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.4rem;
  border: 1px solid var(--border-color);
  border-radius: 0.25rem;
  background: var(--background-color);
}

.asimov-form .attachments-form .recording-time {
  font-size: 0.5rem;
  font-variant-numeric: tabular-nums;
  color: var(--color-2);
}

.asimov-form .attachments-form .recording-meter {
  display: flex;
  align-items: flex-end;
  gap: 1px;
  height: 1rem;
}

.asimov-form .attachments-form .meter-bar {
  display: block;
  width: 3px;
  height: 0.2em;
  background: var(--border-color);
  border-radius: 1px;
  transition: height 80ms ease, background 80ms ease;
}

.asimov-form .attachments-form .meter-bar.active {
  background: #2e7d32;
}

.asimov-form .attachments-form .recording-cancel {
  color: var(--color-1);
}

.asimov-form .attachments-form .attachment-item.pending-recording {
  border: 1px dashed var(--color-2);
}

.asimov-form .attachments-form .record-button[aria-busy='true'] {
  color: red;
}

.asimov-form .attachments-form .recording-discard {
  color: red;
}

.asimov-form .attachments-form .attachment-item .play-button {
  width: 1.25rem;
  height: 1.25rem;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  color: var(--color-2);
  background: var(--background-color);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.asimov-form .attachments-form .attachment-item .play-button .pause-icon {
  display: none;
}

.asimov-form .attachments-form .attachment-item .play-button.playing {
  animation: asf-attachments-play-spin 1.1s linear infinite;
  color: #2e7d32;
  border-color: #2e7d32;
}

.asimov-form .attachments-form .attachment-item .play-button.playing .play-icon {
  display: none;
}

.asimov-form .attachments-form .attachment-item .play-button.playing .pause-icon {
  display: inline-flex;
}

@keyframes asf-attachments-play-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}


.asimov-form .markdown-content {
  min-height: 2.5rem;
  background-color: var(--background-12);
  border: 1px solid var(--background-1);
  padding: 0.75rem 0.75rem 0.75rem 1rem;
  margin-bottom: 0.5rem;
  border-radius: var(--border-radius);
}

.asimov-form .clojure-form,
.asimov-form .markdown-form {
  /* margin-bottom: 0.5rem; */
  border-radius: var(--border-radius);
}

.asimov-form .table-row table {
  margin-bottom: 0;
}

.asimov-form .table-row thead th,
.asimov-form .table-row thead td {
  border-width: 1px;
  border-color: var(--primary);
  font-size: 0.6rem;
  color: var(--color-5);
  /* text-align: center; */
}

.asimov-form .table-row tbody th,
.asimov-form .table-row tbody td {
  padding: 0.5rem;
}

.asimov-form .table-row th {
  /* font-size: 1rem; */
  font-size: 0.6rem;
}

.asimov-form .table-row td pre,
.asimov-form .table-row td select,
.asimov-form .table-row td textarea,
.asimov-form .table-row td input {
  margin-bottom: 0;
  border-color: var(--background-1);
  /* border: none; */
  /* background-color: transparent; */
}

.asimov-form .table-row td pre.plain {
  background: none;
  color: var(--color-1);
  font-size: 0.6rem;
  text-wrap: auto;
  white-space: pre-wrap;
  word-break: break-all;
  overflow-wrap: anywhere;
  max-width: 20rem;
}

.asimov-form .table-row td span.rich span.head {
  color: var(--color-2);
}

.asimov-form .table-row td span.rich span.body {
  color: var(--color-1);
}

.asimov-form .table-row td .link-text {
  display: inline-flex;
  gap: 0.25rem;
  align-items: center;
}

.asimov-form .table-row td .link-text .open-link {
  font-size: 0.6rem;
}

.asimov-form .table-row table th.asf-table-selector-col,
.asimov-form .table-row table td.asf-table-selector-col {
  width: 1.75rem;
  min-width: 1.75rem;
  max-width: 1.75rem;
  text-align: center;
}

.asimov-form .table-row table th.asf-table-row-actions-col,
.asimov-form .table-row table td.asf-table-row-actions-col {
  width: 4rem;
  min-width: 4rem;
  max-width: 4rem;
  text-align: center;
  white-space: nowrap;
}

.asimov-form .table-row table th.asf-table-checkbox-col,
.asimov-form .table-row table td.asf-table-checkbox-col {
  width: 2.75rem;
  min-width: 2.75rem;
  max-width: 2.75rem;
  padding: 0 0.15rem;
  margin: 0;
  text-align: center;
}

.asimov-form .toolbar-row [role=button] {
  margin: 0.1rem 0.3rem;
  vertical-align: bottom;
}

.asimov-form .toolbar-row .icon-button {
  margin: 0.1rem 0.3rem;
  font-size: 1rem;
  line-height: 1.5rem;
  text-align: center;
}

.asimov-form .asf-table-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.25rem 0;
}

.asimov-form .asf-table-filter .asf-table-filter-input {
  width: 12rem;
  max-width: 100%;
  padding: 0.15rem 0.4rem;
  margin: 0;
  font-size: 0.6rem;
  line-height: 1rem;
}

.asimov-form .asf-table-filter .asf-table-filter-clear {
  padding: 0 0.2rem;
  font-size: 0.6rem;
  line-height: 1rem;
  cursor: pointer;
}

.asimov-form .asf-table-filter .asf-table-filter-count {
  color: var(--color-2);
  font-size: 0.6rem;
  white-space: nowrap;
}

.asimov-form .table-row table:not(.popup-table):not(.show-hidden-cols) th.popup-table-only,
.asimov-form .table-row table:not(.popup-table):not(.show-hidden-cols) td.popup-table-only {
  display: none;
}

/* Timeine chart */

.asimov-form .timeline {
  position: relative;
  padding: 0.5rem 0;
}

.asimov-form .timeline .timeline-title {
  color: var(--color-orange);
  margin-bottom: 0;
}

.asimov-form .timeline .timeline-chart {
  min-height: 10rem;
  width: 100%;
  margin-top: 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.25rem;
}

.asimov-form .timeline .timeline-x-range {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 10rem;
}

.asimov-form .text-label {
  font-weight: bold;
  width: fit-content;
  border-radius: 0.6rem;
  color: white;
  border: 1px solid var(--color-silver);
  padding: 0 1rem;
  background: none;
}

.asimov-form .url-preview {
  position: relative;
  font-size: 0.7rem;
}

.asimov-form .url-preview:not(:hover) .thumbnail {
  display: none;
}

.asimov-form .url-preview .thumbnail {
  position: absolute;
  top: 50%;
  left: -0.5rem;
  transform: translate(-100%,-50%);
  background: #333;
  padding: 0.5rem;
  width: 10rem;
}

.asimov-form .url-preview .thumbnail img {}

/* Checklist progress */

.asimov-form .item-checklist {
  font-size: 0.6rem;
}

.asimov-form .item-checklist > * {
  margin-top: 0.25rem;
}

.asimov-form .item-checklist .overall {
  display: flex;
  flex-wrap: wrap;
}

.asimov-form .item-checklist .info {
  margin-left: 1rem;
}

.asimov-form .item-checklist .info:first-child {
  margin-left: auto;
}

.asimov-form .item-checklist .overall .info .label {
  padding: 0 0.2rem 0 0;
}

.asimov-form .item-checklist .overall .info .label::after {
  content: ":"
}

.asimov-form .item-checklist .overall .info .value {
  padding: 0;
  color: var(--color-green);
}

.asimov-form .item-checklist .overall .info .value.failed {
  color: var(--color-red);
}

.asimov-form .item-checklist .overall .info .value.pending {
  color: var(--color-orange);
}

.asimov-form .item-checklist .progress-bar {
  position: relative;
  height: 1rem;
  margin: 0.5rem 0;
  background: var(--background-color-2);
  border-radius: var(--border-radius);
}

.asimov-form .item-checklist .progress-bar.complete {
  background: var(--color-green);
  opacity: 40%;
}

.asimov-form .item-checklist .progress-bar .bar {
  position: absolute;
  left: 0;
  background: var(--color-orange);
  height: 100%;
  min-width: 0.25rem;
  border-radius: inherit;
}

.asimov-form .item-checklist .task {
  position: relative;
  display: flex;
  padding: 0.5rem 0.25rem 0.5rem 2rem;
  color: var(--color-1);
}

.asimov-form .item-checklist .task .status {
  margin: 0;
  width: 1rem;
  height: 1rem;
  position: absolute;
  left: 0.5rem;
  top: 0.5rem;
  border-radius: 50%;
  background-color: var(--background-6);
  z-index: 1;
}

.asimov-form .item-checklist .task .status.complete {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-line-join='round' %3E%3Cpath d='M20 6 9 17l-5-5'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

.asimov-form .item-checklist .task .status.failed {
  background-color: var(--color-red);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-line-join='round' %3E%3Cpath d='M6 6 19 19 M6 19 19 6'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

.asimov-form .item-checklist .task .status[aria-busy=true] {
  padding-top: 0.12rem;
}

.asimov-form .item-checklist .task:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 1rem;
  top: 50%;
  height: 100%;
  border-left: 1px dashed var(--color-3);
}

.asimov-form .item-checklist .task .title {
  flex: 1;
  margin-left: 0.8rem;
  line-height: 1rem;
}

.asimov-form .item-checklist .task .title div {
  font-size: 0.8em;
  color: var(--color-2);
}

.asimov-form .item-checklist .task .time {
  color: var(--color);
  opacity: 40%;
}

.asimov-form .flashGreen {
  animation-duration: 1s;
  animation-name: flashGreen;
}

@keyframes flashGreen {
  from {
    box-shadow: 0 0 0.5rem 0.5rem var(--color-green);
  }

  to {}
}

.asimov-form .attachments-input {
  background-image: url('/lib_asimov-form/attachments.svg');
  background-repeat: no-repeat;
  background-position: 0.5rem;
  background-size: 0.7rem;
  padding-left: 1.5rem;
  cursor: pointer;
}

.attachments-dialog {}

.attachments-dialog .file-list {
  padding: 0.5rem;
  margin-bottom: 0;
}

.attachments-dialog .file-list .file {
  display: flex;
  padding: 0.125rem;
  border-bottom: 1px solid var(--border-color);
  justify-content: space-between;
}

.attachments-dialog .file-list .remove {
  color: var(--asv-color-red);
  cursor: pointer;
  padding: 0 0.25rem;
  margin-left: 0.5rem;
  border-radius: 0.2rem;
  line-height: 1rem;
  font-weight: 700;
}

.attachments-dialog .file-list .remove:hover {
  background: var(--asv-color-red);
  color: white;
}

.attachments-dialog [role=button] {
  margin: 0 0.25rem;
  width: 6rem;
}


.asimov-form .picker-row .tool-picker-input,
.asimov-form .picker-row .item-picker-input,
.asimov-form .picker-row .project-selector-input,
.asimov-form .picker-row .channel-selector-input,
.asimov-form .picker-row .item-selector-input {
  border-color: transparent;
  background-image: url('/lib_asimov-form/item-selector.svg');
  background-repeat: no-repeat;
  background-position: 0.5rem;
  background-size: 0.7rem;
  padding-left: 2rem;
  cursor: pointer;
}

.asimov-form .project-selector:has(.control) .picker-body,
.asimov-form .channel-selector:has(.control) .picker-body,
.asimov-form .item-selector:has(.control) .picker-body {
  display: none;
}

.asimov-form .project-selector article,
.asimov-form .channel-selector article,
.asimov-form .item-selector article {
  margin-top: 0;
}

.asimov-form .project-selector:not(.can-create) .create-button,
.asimov-form .channel-selector:not(.can-create) .create-button,
.asimov-form .item-selector:not(.can-create) .create-button {
  display: none;
}

.asimov-form .transcription {
  position: relative;
}

.asimov-form .transcription .microphone {
  display: flex;
  position: absolute;
  width: fit-content;
  right: 1rem;
  bottom: 0;
  user-select: none;
}

.asimov-form .transcription .microphone * {
  user-select: none;
}

.asimov-form .transcription .microphone .message {
  /* font-size: 0.8em; */
  /* height: 1.3rem; */
  padding: 0.25rem 0.5rem;
  border-radius: var(--border-radius);
  background: #633;
}

.asimov-form .transcription .microphone .message .end,
.asimov-form .transcription .microphone .message .cancel {
  width: fit-content;
  margin: 0 0.1rem;
  font-size: 0.6rem;
  padding: 0 0.2rem;
  float: right;
}

.asimov-form .transcription .microphone .message:not(.shown) {
  display: none;
}

.asimov-form .transcription:has(.microphone) input {
  padding-right: 3.5rem!important;
}

.asimov-form .transcription:has(input) .microphone {
  bottom: 0;
}

.asimov-form .transcription:has(.microphone) textarea {
  padding-right: 2.5rem!important;
}

.asimov-form .transcription:has(textarea) .microphone {
  bottom: 0.25rem;
}

.asimov-form .transcription .microphone .icon-button[aria-busy='true'] {
  padding: 0.25rem 0.4rem;
}

.asimov-form .transcription .microphone .icon-button[aria-busy='true'] svg {
  display: none;
}

.asimov-form .icon-button.faicon {
  font-size: 0.8rem;
  line-height: 1.5rem;
  text-align: center;
}

.asimov-form .picker-row {
  display: flex;
  background: var(--background-12);
  margin-bottom: 0.25rem;
  border: 1px solid var(--background-1);
}

.asimov-form .picker-row .icon-button {
  margin-top: 0.5rem;
}

.asimov-form .open-link.icon-button[href='#'] {
  display: none;
}

.asimov-form .formative-section .formative-row .CodeMirror {
  background: var(--background-12);
  min-height: 3rem;
}

/* EDN field renderer */

.asimov-form .edn-content {
  font-family: Consolas, Monaco, 'Andale Mono', monospace;
  font-size: 13px;
  line-height: 1.5;
  color: #cdd6f4;
  background: #1e1e2e;
  padding: 8px;
  overflow-x: auto;
}

.asimov-form .edn-legend {
  font-size: 12px;
  padding: 4px 8px;
  margin-bottom: 8px;
  background: #181825;
  border: 1px solid #585b70;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.asimov-form .edn-legend strong {
  color: #a6adc8;
  margin-right: 4px;
}

.asimov-form .edn-legend span {
  padding: 1px 4px;
  border-radius: 2px;
  font-weight: 600;
  font-size: 11px;
}

.asimov-form .edn-node {
  border-collapse: collapse;
  width: 100%;
  border: 2px solid #585b70;
  margin: 5px 0;
}

.asimov-form .edn-node thead th {
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  text-align: left;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  color: #fff;
}

.asimov-form .edn-node tbody td {
  padding: 2px 6px;
  border: 1px solid #585b70;
  vertical-align: top;
  font-size: 12px;
  background: #313244;
  min-width: 100px;
}

.asimov-form .edn-node .edn-idx {
  background: #1e1e2e;
  color: #6c7086;
  text-align: right;
  width: 36px;
  min-width: 36px;
  font-size: 11px;
  white-space: nowrap;
  user-select: none;
}

.asimov-form .edn-node .edn-key {
  background: #1e1e2e;
  white-space: nowrap;
  min-width: 80px;
}

.asimov-form .edn-node .edn-val {
  background: #313244;
}

.asimov-form [data-type="mapping"]>thead th {
  background: #3b6ea5;
}

.asimov-form [data-type="vector"]>thead th {
  background: #40a02b;
}

.asimov-form [data-type="list"]>thead th {
  background: #40a02b;
}

.asimov-form [data-type="set"]>thead th {
  background: #179299;
}

.asimov-form .edn-nil {
  color: #c8c8c8;
  font-style: italic;
}

.asimov-form .edn-bool {
  color: #ff6b6b;
  font-weight: 600;
}

.asimov-form .edn-num {
  color: #ffa502;
}

.asimov-form .edn-str {
  color: #ffe566;
}

.asimov-form .edn-kw {
  color: #5cd859;
  font-weight: 600;
}

.asimov-form .edn-sym {
  color: #54a0ff;
}

.asimov-form .edn-char {
  color: #c085f0;
}

.asimov-form [data-depth="0"] {
  border-left: 4px solid #89b4fa !important;
}

.asimov-form [data-depth="1"] {
  border-left: 4px solid #a6e3a1 !important;
}

.asimov-form [data-depth="2"] {
  border-left: 4px solid #f38ba8 !important;
}

.asimov-form [data-depth="3"] {
  border-left: 4px solid #f9e2af !important;
}

.asimov-form [data-depth="4"] {
  border-left: 4px solid #cba6f7 !important;
}

.asimov-form [data-depth="5"] {
  border-left: 4px solid #94e2d5 !important;
}

.asimov-form [data-depth="6"] {
  border-left: 4px solid #f5c2e7 !important;
}

.asimov-form [data-depth="7"] {
  border-left: 4px solid #89b4fa !important;
}

.asimov-form [data-depth="8"] {
  border-left: 4px solid #a6e3a1 !important;
}

.asimov-form [data-depth="9"] {
  border-left: 4px solid #f38ba8 !important;
}

.asimov-form .edn-node>tbody>tr:hover>td {
  background: #45475a !important;
}

.asimov-form .edn-node>tbody>tr:hover>.edn-idx {
  background: #313244 !important;
}

.asimov-form .edn-node>tbody>tr:hover>.edn-key {
  background: #313244 !important;
}

/* really small screen like iPhone */

@media screen and (max-width:400px) {
  .asimov-form .formative-section {
    padding: 0.25rem;
    margin: 0 0 0.25rem 0;
  }

  .asimov-form .formative-section .formative-row {
    width: calc(100% - 0.5rem);
  }

  .asimov-form .formative-row:not(.heading-row) {
    padding: 0.25rem 0.5rem;
    margin: 0.25rem;
  }

}
