Consider this layout configuration:
<div id="PARENT_DIV">
<div id="LEFT_CHILD_DIV">
</div>
<div id="RIGHT_CHILD_DIV">
</div>
</div>
Key features for PARENT_DIV:
PARENT_DIV must have a higher z-index than all other GUI elements.
PARENT_DIV should dynamically expand in width and height based on the sizes of LEFT_CHILD_DIV and RIGHT_CHILD_DIV. There should be limits set using max-width and max-height properties. For vertical expansion, it should match the taller child div (up to max-height), with the other child floating to the top.
- The positioning of PARENT_DIV on the screen should be customizable through various methods like setting top and left values, percentages, or transformations.
Guidelines for LEFT_CHILD_DIV and RIGHT_CHILD_DIV:
LEFT_CHILD_DIV and RIGHT_CHILD_DIV should expand horizontally and vertically based on their content, following max-width and max-height restrictions set independently for each.
They should always appear side by side, regardless of their maximum widths.
If they reach the maximum height limit imposed either by max-height rules or the parent's max-height, vertical scrolling should activate to accommodate the overflowing content.
Refer to this visual mock-up for clarity on the desired layout. Despite trying various CSS combinations involving display, overflow, box-sizing, position, etc., I haven't found a single tutorial covering all requirements. Seeking insights on achieving these goals purely through CSS without resorting to JavaScript solutions.
While I can achieve this with JavaScript, preference is to explore a script-free CSS approach.