.CIG[data-type='com.psddev.cms.db.ContentForm'] {
  @apply gap-x-8 @admin-two-columns/admin-widget:grid @admin-two-columns/admin-widget:grid-cols-[repeat(2,_minmax(296px,_1fr))];
}

.CIG[data-type='com.psddev.cms.db.ContentForm'] > .CIG-row {
  @apply col-span-full;
}

.CIG[data-type='com.psddev.cms.db.ContentForm']
  > .CIG-row:where([data-field='hiddenItems'], [data-field='visibleFields']) {
  @apply @admin-two-columns/admin-widget:col-span-1;
}

.CIG[data-type='com.psddev.cms.db.ContentForm']
  > .CIG-row:where([data-field='hiddenItems'], [data-field='visibleFields'])
  > .CIG-large
  > .RCIG-list
  > li {
  @apply grid-cols-[1fr_repeat(3,auto)];
}

.CIG[data-type='com.psddev.cms.db.ContentForm'] {
  > .CIG-row[data-field='contentType'],
  > .CIG-row[data-field='hiddenItems'] > .CIG-large > .RCIG-controls,
  > .CIG-row:where([data-field='hiddenItems'], [data-field='visibleFields'])
    > .CIG-large
    > .RCIG-list
    > li
    > :where(.RCIG-remove, btu-dropdown) {
    @apply hidden;
  }
}

.CIG[data-type='com.psddev.cms.db.ContentForm']
  > .CIG-row[data-field='hiddenItems'] {
  > .CIG-large {
    @apply h-[calc(100%-theme(iconSize.md)-theme(spacing.20))];
  }

  > .CIG-large > .RCIG-list {
    @apply empty:after:message h-full empty:before:btu-icon empty:before:btu-icon-info empty:isolate empty:before:absolute empty:before:left-[17px] empty:before:top-[5px] empty:before:z-[1] empty:after:!ps-12 empty:after:content-["Nothing_hidden_yet!_Drag_visible_items_here_to_hide_them."] md:empty:before:top-[17px];
  }
}

.RCIG-toggleButton {
  @apply btu-button btu-button-text-hidden btu-button-fill-none btu-button-gray btu-button-xs bg-white before:btu-icon before:btu-icon-circle-arrow-right touch-device:btu-button-sm;

  .CIG-row[data-field='hiddenItems'] & {
    @apply before:btu-icon-circle-arrow-left;
  }
}

/* Hides "Widget" option from RCIG-addSelect under Visible Items field */
.ComboInput-option[data-value='Widget'] {
  @apply hidden;
}

/* Hides elements nested within Hidden/Visible Items */
.CIG:where(
    [data-type='com.psddev.cms.db.ContentFormCluster'],
    [data-type='com.psddev.cms.db.ContentFormTab']
  )
  > .CIG-row[data-field='fields']
  > .CIG-large {
  > .RCIG-list > li > .RCIG-remove,
  > .RCIG-controls {
    @apply hidden;
  }

  > .RCIG-list > .RCIG-item {
    @apply grid-cols-[1fr_repeat(3,auto)];
  }
}

.CIG[data-type='com.psddev.cms.db.ContentFormField']
  > .CIG-row[data-field='internalName'] {
  @apply hidden;
}

.CIG[data-type='com.psddev.cms.db.ContentFormWidget']
  > .CIG-row:where([data-field='widget'], [data-field='name']) {
  @apply hidden;
}

.CIG[data-type='com.psddev.cms.db.ContentFormTab'][data-tc-main='Main'] {
  @apply !px-6;
}
