//** Fields | Collection

.collection-container {
  .expand-buttons {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;

    .btn-group {
      height: min-content;
    }
  }

  .collection-item {
    margin-bottom: 1rem;

    .summary {
      padding: 0;
      background: transparent;
      cursor: pointer;

      &::-webkit-details-marker {
        display: none;
      }

      &:focus {
        outline: none;
      }

      i.card-marker-caret {
        margin-right: 0.75rem;
        transform: rotate(90deg);
      }
    }

    &.collapsed {
      .summary i.card-marker-caret {
        transform: rotate(0);
      }
    }

    .collection-item-title {
      display: inline-block;
      //max-width: 40%;
      text-overflow: ellipsis;
      white-space: nowrap;
      overflow: hidden;
      user-select: none;
    }

    &.collapsed .details {
      display: none;
    }

    .card-body {
      background: var(--background);
      // 1px solves the ghosted whitespace
      // @see https://github.com/bolt/core/pull/1904

      padding-bottom: 1px;
    }

    .card-header {
      padding: 0.8125rem 0.8125rem;
    }
  }
}
