Indents
There is no bug. “Text containers” in Writer are based on an HTML-like model. Every “container” has (outer) margins (bearing various names in Writer; this is not very consistent), a border and (inner) padding space surrounding the text.
- A section has no margin not border, only padding space called Indent in the configuration dialog
- A paragraph is a full-fledged box with “margins” called indents horizontally and spacing vertically, a border and padding
When a paragraph is nested in a section, you add up section indents and paragraph properties.
Your original document in inserted in a section called Whole Document which is created from scratch. Whole contents is imported without modification, including the inner section called Linked text. In the imported document, this section has its own indents set at 1.27cm (1/2") at left and right.
You created a section called Section only where you inserted partial contents from the other document. You didn’t define any indents for this one.
In both sections, text is formatted by Text Body which has no indents. Consequently the difference comes only from the difference in section configuration.
Background colour
Once again, you have to look at the section configurations. In the imported document, section Linked text has a background colour while your fresh section Section only has no background.
Unfortunately, there is no “section style” which would solve this consistency issue. You must be manually careful about your section parametrisation.
PS: By the way, your use of “linked” word is faulty (causing confusion). “Linked” would hint at some “reference” to the other file without copying contents. This allows to update automatically referenced contents when the external object is changed (dynamic behaviour). You inserted the file into a section, in effect copying the contents and freezing it to the state at time of insertion (static behaviour).
Here a better word would have been “nested” because you have a section inside a section. Hence my request for a sample file to see exactly how you proceeded.