<html>
<head>
<title>Container Spacing Test</title>
</head>
<body>
<h1>Container Spacing Test Document</h1>
<p>This document tests spacing behavior in all container types with multiple paragraphs.</p>
<h2>1. Lists with Multiple Paragraphs</h2>
<h3>Unordered List</h3>
<ul>
<li>
<p>First list item, first paragraph. This should flow naturally.</p>
<p>First list item, second paragraph. There should be NO extra blank lines between these paragraphs.</p>
<p>First list item, third paragraph. Still no extra spacing.</p>
</li>
<li>
<p>Second list item, first paragraph.</p>
<p>Second list item, second paragraph. Again, no extra spacing within the same item.</p>
</li>
<li>
<p>Third list item with a single paragraph only.</p>
</li>
</ul>
<h3>Ordered List</h3>
<ol>
<li>
<p>Step one, first paragraph explaining the process.</p>
<p>Step one, second paragraph with more details. No extra blank lines.</p>
</li>
<li>
<p>Step two, single paragraph.</p>
</li>
<li>
<p>Step three, first paragraph.</p>
<p>Step three, second paragraph.</p>
<p>Step three, third paragraph. All tight together.</p>
</li>
</ol>
<h2>2. Blockquotes with Multiple Paragraphs</h2>
<blockquote>
<p>First paragraph of the quote. This represents someone's words.</p>
<p>Second paragraph of the same quote. Should flow continuously without extra spacing.</p>
<p>Third paragraph concluding the quote. Still part of the same quotation block.</p>
</blockquote>
<p>Regular paragraph between quotes.</p>
<blockquote>
<p>Another quote with just two paragraphs.</p>
<p>Second paragraph of this quote.</p>
</blockquote>
<h2>3. Definition Lists with Multiple Paragraphs</h2>
<dl>
<dt>First Term</dt>
<dd>
<p>First definition paragraph explaining the term.</p>
<p>Second definition paragraph with additional context. No extra spacing.</p>
<p>Third definition paragraph with examples.</p>
</dd>
<dt>Second Term</dt>
<dd>
<p>Single paragraph definition.</p>
</dd>
<dt>Third Term</dt>
<dd>
<p>First definition for third term.</p>
<p>Second definition paragraph.</p>
</dd>
<dd>
<p>Alternative definition, first paragraph.</p>
<p>Alternative definition, second paragraph.</p>
</dd>
</dl>
<h2>4. Nested Containers</h2>
<h3>List Inside Blockquote</h3>
<blockquote>
<p>Introduction to the quoted list.</p>
<ul>
<li>
<p>First item in quoted list.</p>
<p>Second paragraph of first item.</p>
</li>
<li>
<p>Second item in quoted list.</p>
</li>
</ul>
<p>Conclusion of the quote.</p>
</blockquote>
<h3>Blockquote Inside List</h3>
<ul>
<li>
<p>List item starts here.</p>
<blockquote>
<p>First paragraph of nested quote.</p>
<p>Second paragraph of nested quote.</p>
</blockquote>
<p>List item continues after quote.</p>
</li>
<li>
<p>Another list item.</p>
</li>
</ul>
<h3>Nested Lists</h3>
<ul>
<li>
<p>Outer list item, first paragraph.</p>
<p>Outer list item, second paragraph.</p>
<ul>
<li>
<p>Nested list item, first paragraph.</p>
<p>Nested list item, second paragraph.</p>
</li>
<li>
<p>Another nested item.</p>
</li>
</ul>
<p>Outer list item continues.</p>
</li>
</ul>
<h2>5. Mixed Content in Containers</h2>
<ul>
<li>
<p>Paragraph before code block.</p>
<pre><code>function example() {
return "code block";
}</code></pre>
<p>Paragraph after code block. Should have minimal spacing.</p>
</li>
<li>
<p>Item with <strong>bold</strong> and <em>italic</em> text in multiple paragraphs.</p>
<p>Second paragraph with <code>inline code</code> and regular text.</p>
</li>
</ul>
<h2>6. Edge Cases</h2>
<h3>Single Paragraph in Container</h3>
<ul>
<li><p>Single paragraph item - should still work correctly.</p></li>
<li><p>Another single paragraph item.</p></li>
</ul>
<h3>Empty and Whitespace</h3>
<ul>
<li>
<p>First paragraph.</p>
<p>Second paragraph.</p>
<p>Third paragraph.</p>
</li>
</ul>
<h2>Expected Behavior</h2>
<p>In all the above cases:</p>
<ul>
<li><p>Multiple paragraphs within the SAME container item should have NO extra blank lines between them.</p></li>
<li><p>Different items (list items, definition terms, separate quotes) SHOULD have proper spacing between them.</p></li>
<li><p>Top-level paragraphs (not in containers) SHOULD have normal spacing.</p></li>
</ul>
<p>This is the end of the test document.</p>
</body>
</html>