The core of CSS: floating, box model, positioning
Div is a block-level element, with each div occupying one line.
Block element Features: 1. The default is displayed in the upper-left corner of the parent tag; 2. The accounting element fills the line by default (full document flow)
Common block-level elements: P, H1-H6, ul Li, Ol Li, Div, table, HR, etc.
Corresponds to the inline element (inline Element): A, span, IMG, input, etc.
Features of inline elements: 1. The size is affected by the text area, not affected by height and width; 2. Does not occupy a single row.
Application of the span tag: does not occupy a single row, and is not affected by other block-level elements
The inline element becomes a block-level element: Display:block;
Block-level element programming inline elements: display:inline;
Display:inline-block; Affected by aspect, does not occupy a single line. (Block-level elements, inline elements are valid)
In order for the two div to be arranged in a row, it needs to be set by a float.
CSS (The Four)