# Markdown Test Document
This document tests various Markdown syntax elements for rendering.
## Headers
# H1
## H2
### H3
#### H4
##### H5
###### H6
Alternative H1
==============
Alternative H2
--------------
## Text Formatting
**Bold text**
__Also bold__
*Italic text*
_Also italic_
***Bold and italic***
~~Strikethrough~~
`Inline code`
<kbd>Keyboard input</kbd>
## Lists
### Unordered Lists
- Item 1
- Item 2
- Nested item 2.1
- Nested item 2.2
- Deeply nested item
- Item 3
### Ordered Lists
1. First item
2. Second item
1. Nested item 2.1
2. Nested item 2.2
3. Third item
### Mixed Lists
- Item with numbers
1. Nested ordered
2. Another ordered
- Another bullet
- Nested bullet
- Deep bullet
1. Mixed with ordered
### Task Lists
- [ ] Unchecked task
- [x] Checked task
- [ ] Another unchecked task
- [x] Nested checked
- [ ] Nested unchecked
## Links and References
[Inline link](https://example.com)
[Link with title](https://example.com "Example Title")
[Reference link][reference]
[Relative link](./path/to/file.md)
[Anchor link](#headers)
[reference]: https://example.com/reference
Autolink: <https://example.com>
Email: <[email protected]>
## Images

![Reference image][img_ref]
[img_ref]: https://picsum.photos/150/75 "Reference image"
## Code
Inline `code` example.
```python
# Code block with syntax highlighting
def hello_world():
print("Hello, World!")
return True
```
```
Plain code block without syntax highlighting
Line 2
Line 3
```
```bash
#!/bin/bash
echo "Shell script"
ls -la
```
## Blockquotes
> Single level blockquote.
> Continuing on the same line.
>
> New paragraph within blockquote.
> > Nested blockquote
> > Second line of nested quote
>
> Back to first level
> **Blockquote with formatting**
> - List inside blockquote
> - Another item
>
> ```python
> # Code in blockquote
> print("test")
> ```
## Horizontal Rules
---
***
___
## Tables
| Syntax | Description | Test |
|--------|-------------|------|
| Header | Title | Data |
| Paragraph | Text | More |
| Left-aligned | Center-aligned | Right-aligned |
|:-------------|:--------------:|--------------:|
| Left | Center | Right |
| Data | More data | Numbers |
| Header 1 | Header 2 | Header 3 |
|----------|----------|----------|
| Cell spanning columns |||
| Normal cell | **Bold** | *Italic* |
## HTML Elements
<div style="background: #f0f0f0; padding: 10px;">
HTML block with <span style="color: red;">styled</span> content.
</div>
<br>
<details>
<summary>Click to expand</summary>
Hidden content here.
</details>
## Escaped Characters
\*Not italic\*
\# Not a header
\[Not a link\]
## Emoji
:smile: :heart: :rocket: :+1:
## Footnotes
Here's a sentence with a footnote.[^1] And another.[^2]
[^1]: First footnote definition.
[^2]: Second footnote with **formatting**.
## Definition Lists
Term 1
: Definition 1
Term 2
: Definition 2a
: Definition 2b
## Math (if supported)
Inline math: $E = mc^2$
Block math:
$$
\int_{-\infty}^{\infty} e^{-x^2} dx = \sqrt{\pi}
$$
## Special Cases
### Empty Lines Between Elements
Above are two empty lines.
### Very Long Lines
This is a very long line that should wrap appropriately in the renderer. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
### Edge Cases
- [ ] Empty task item
- Item ending with `backtick`
- **Bold with __nested__ formatting**
- [Link]() with empty URL
- ![Image]() with empty source
### Mixed Inline Formatting
This has **bold**, *italic*, `code`, ~~strikethrough~~, and a [link](test.md) all in one sentence with **bold containing *italic* inside**.
## End of Document