Layout là UI chia sẻ giữa nhiều pages, preserve state khi navigate (không remount). layout.tsx nhận children prop.
- Nested layouts: layout lồng trong layout tạo hierarchy.
- Root layout (
app/layout.tsx) bắt buộc phải có, wrap toàn app. - Khác với template.tsx: template remount mỗi navigate.